diff options
author | stijn <stijn@ignitron.net> | 2024-03-26 16:09:15 +0100 |
---|---|---|
committer | Damien George <damien@micropython.org> | 2024-07-25 16:22:21 +1000 |
commit | a0c7bf12d21bd51e8af4acab466a6c124c480fa7 (patch) | |
tree | 11fbad8e5291684033ac5cad510defa665ca575c /tests/run-tests.py | |
parent | 233f5ce661d31c8e606ff727ac0c6de27d32a715 (diff) |
github/workflows: Improve MSYS2-based CI builds.
Install the mingw variant of Python since it behaves more like a 'real'
Windows CPython than the msys2 variant: os.name == 'nt', not 'posix'. Note
that os.sep is still '/' though so we don't actually need to skip the
import_file test. This way one single Python version can be used both for
running run-tests.py and getting the expected test output.
Signed-off-by: stijn <stijn@ignitron.net>
Diffstat (limited to 'tests/run-tests.py')
-rwxr-xr-x | tests/run-tests.py | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/tests/run-tests.py b/tests/run-tests.py index e80d5b463..a91b3e9e9 100755 --- a/tests/run-tests.py +++ b/tests/run-tests.py @@ -3,6 +3,7 @@ import os import subprocess import sys +import sysconfig import platform import argparse import inspect @@ -583,10 +584,6 @@ def run_tests(pyb, tests, args, result_dir, num_threads=1): # fails with stack overflow on Debug builds skip_tests.add("misc/sys_settrace_features.py") - if os.getenv("MSYSTEM") is not None: - # fails due to wrong path separator - skip_tests.add("import/import_file.py") - if upy_float_precision == 0: skip_tests.add("extmod/uctypes_le_float.py") skip_tests.add("extmod/uctypes_native_float.py") @@ -711,7 +708,9 @@ def run_tests(pyb, tests, args, result_dir, num_threads=1): # Some tests use unsupported features on Windows if os.name == "nt": - skip_tests.add("import/import_file.py") # works but CPython prints forward slashes + if not sysconfig.get_platform().startswith("mingw"): + # Works but CPython uses '\' path separator + skip_tests.add("import/import_file.py") # Some tests are known to fail with native emitter # Remove them from the below when they work |