]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-90473: Skip get_config_h() tests on WASI (GH-93645)
authorChristian Heimes <christian@python.org>
Thu, 9 Jun 2022 16:08:03 +0000 (18:08 +0200)
committerGitHub <noreply@github.com>
Thu, 9 Jun 2022 16:08:03 +0000 (18:08 +0200)
Lib/distutils/tests/test_sysconfig.py
Lib/test/test_sysconfig.py

index e7d435f412db797080f89ea475a9145fb01a4618..0664acade82cd1f5b6efa54963688578747d549d 100644 (file)
@@ -10,7 +10,7 @@ import unittest
 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 @@ class SysconfigTestCase(support.EnvironGuard, unittest.TestCase):
         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)
index f2b93706b270a74bb177ba34166b36749af4be99..1679700f59296f97cc2a447f1298391d5e1c36bc 100644 (file)
@@ -5,7 +5,9 @@ import subprocess
 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 @@ class TestSysConfig(unittest.TestCase):
 
         # 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)