[Python-checkins] gh-90473: Skip get_config_h() tests on WASI (GH-93645)
tiran
webhook-mailer at python.org
Thu Jun 9 12:08:11 EDT 2022
https://github.com/python/cpython/commit/6099611af5b9688f015ae4796501ce101a1c2f32
commit: 6099611af5b9688f015ae4796501ce101a1c2f32
branch: main
author: Christian Heimes <christian at python.org>
committer: tiran <christian at python.org>
date: 2022-06-09T18:08:03+02:00
summary:
gh-90473: Skip get_config_h() tests on WASI (GH-93645)
files:
M Lib/distutils/tests/test_sysconfig.py
M Lib/test/test_sysconfig.py
diff --git a/Lib/distutils/tests/test_sysconfig.py b/Lib/distutils/tests/test_sysconfig.py
index e7d435f412db7..0664acade82cd 100644
--- a/Lib/distutils/tests/test_sysconfig.py
+++ b/Lib/distutils/tests/test_sysconfig.py
@@ -10,7 +10,7 @@
from distutils import sysconfig
from distutils.ccompiler import get_default_compiler
from distutils.tests import support
-from test.support import run_unittest, swap_item, requires_subprocess
+from test.support import run_unittest, swap_item, requires_subprocess, is_wasi
from test.support.os_helper import TESTFN
from test.support.warnings_helper import check_warnings
@@ -32,6 +32,7 @@ def cleanup_testfn(self):
elif os.path.isdir(TESTFN):
shutil.rmtree(TESTFN)
+ @unittest.skipIf(is_wasi, "Incompatible with WASI mapdir and OOT builds")
def test_get_config_h_filename(self):
config_h = sysconfig.get_config_h_filename()
self.assertTrue(os.path.isfile(config_h), config_h)
diff --git a/Lib/test/test_sysconfig.py b/Lib/test/test_sysconfig.py
index f2b93706b270a..1679700f59296 100644
--- a/Lib/test/test_sysconfig.py
+++ b/Lib/test/test_sysconfig.py
@@ -5,7 +5,9 @@
import shutil
from copy import copy
-from test.support import (captured_stdout, PythonSymlink, requires_subprocess)
+from test.support import (
+ captured_stdout, PythonSymlink, requires_subprocess, is_wasi
+)
from test.support.import_helper import import_module
from test.support.os_helper import (TESTFN, unlink, skip_unless_symlink,
change_cwd)
@@ -328,6 +330,7 @@ def test_get_platform(self):
# XXX more platforms to tests here
+ @unittest.skipIf(is_wasi, "Incompatible with WASI mapdir and OOT builds")
def test_get_config_h_filename(self):
config_h = sysconfig.get_config_h_filename()
self.assertTrue(os.path.isfile(config_h), config_h)
@@ -499,6 +502,7 @@ class MakefileTests(unittest.TestCase):
@unittest.skipIf(sys.platform.startswith('win'),
'Test is not Windows compatible')
+ @unittest.skipIf(is_wasi, "Incompatible with WASI mapdir and OOT builds")
def test_get_makefile_filename(self):
makefile = sysconfig.get_makefile_filename()
self.assertTrue(os.path.isfile(makefile), makefile)
More information about the Python-checkins
mailing list