diff options
| author | Charles Brunet <charles.brunet@optelgroup.com> | 2024-02-28 11:58:29 -0500 |
|---|---|---|
| committer | Dylan Baker <dylan@pnwbakers.com> | 2024-03-01 12:09:22 -0800 |
| commit | 4ed6d75d962b3d43a9f7e8f5154e48d0bef01cc9 (patch) | |
| tree | ba079cd5c44c74e6c8882db3a6dba36f865c04ff /unittests/baseplatformtests.py | |
| parent | c67a6e1d7cdb7883621eaceda9af08b9eecf34a8 (diff) | |
| download | meson-4ed6d75d962b3d43a9f7e8f5154e48d0bef01cc9.tar.gz | |
Set PYTHONIOENCODING when running tests
For instance, on Windows, if the terminal is in cp65001, the subprocess
output is not encoded correctly and it results in error when running
unit test.
Diffstat (limited to 'unittests/baseplatformtests.py')
| -rw-r--r-- | unittests/baseplatformtests.py | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/unittests/baseplatformtests.py b/unittests/baseplatformtests.py index ec3f18908..6125ed933 100644 --- a/unittests/baseplatformtests.py +++ b/unittests/baseplatformtests.py @@ -85,6 +85,7 @@ class BasePlatformTests(TestCase): # XCode backend is untested with unit tests, help welcome! self.no_rebuild_stdout = [f'UNKNOWN BACKEND {self.backend.name!r}'] os.environ['COLUMNS'] = '80' + os.environ['PYTHONIOENCODING'] = 'utf8' self.builddirs = [] self.new_builddir() |
