Open mesontest logfiles in utf-8 mode

Otherwise unit tests fail on windows when they output some
non-utf8 data.
pull/3265/merge
nyorain 7 years ago committed by Jussi Pakkanen
parent 58156ef7cf
commit dd614015e0
  1. 4
      mesonbuild/mtest.py

@ -509,8 +509,8 @@ TIMEOUT: %4d
self.logfilename = logfile_base + '.txt'
self.jsonlogfilename = logfile_base + '.json'
self.jsonlogfile = open(self.jsonlogfilename, 'w')
self.logfile = open(self.logfilename, 'w')
self.jsonlogfile = open(self.jsonlogfilename, 'w', encoding='utf-8')
self.logfile = open(self.logfilename, 'w', encoding='utf-8')
self.logfile.write('Log of Meson test suite run on %s\n\n'
% datetime.datetime.now().isoformat())

Loading…
Cancel
Save