-
-
Notifications
You must be signed in to change notification settings - Fork 145
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
unix: refresh test_embed patches to conditionally skip on BOLT (#469)
Turns out there is a support function to check for BOLT optimization. So we can conditionally skip tests on BOLT. Closes #465.
- Loading branch information
Showing
3 changed files
with
9 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,36 @@ | ||
diff --git a/Lib/test/test_embed.py b/Lib/test/test_embed.py | ||
index 7110fb889f3..61e4d0f6179 100644 | ||
index 7110fb889f3..1b55cd156d7 100644 | ||
--- a/Lib/test/test_embed.py | ||
+++ b/Lib/test/test_embed.py | ||
@@ -940,6 +940,7 @@ def check_all_configs(self, testname, expected_config=None, | ||
self.check_global_config(configs) | ||
return configs | ||
|
||
+ @unittest.skip("segfaults on BOLT instrumented binaries") | ||
+ @unittest.skipIf(support.check_bolt_optimized, "segfaults on BOLT instrumented binaries") | ||
def test_init_default_config(self): | ||
self.check_all_configs("test_init_initialize_config", api=API_COMPAT) | ||
|
||
@@ -1039,6 +1040,7 @@ def test_init_from_config(self): | ||
self.check_all_configs("test_init_from_config", config, preconfig, | ||
api=API_COMPAT) | ||
|
||
+ @unittest.skip("segfaults on BOLT instrumented binaries") | ||
+ @unittest.skipIf(support.check_bolt_optimized, "segfaults on BOLT instrumented binaries") | ||
def test_init_compat_env(self): | ||
preconfig = { | ||
'allocator': ALLOCATOR_FOR_CONFIG, | ||
@@ -1074,6 +1076,7 @@ def test_init_compat_env(self): | ||
self.check_all_configs("test_init_compat_env", config, preconfig, | ||
api=API_COMPAT) | ||
|
||
+ @unittest.skip("segfaults on BOLT instrumented binaries") | ||
+ @unittest.skipIf(support.check_bolt_optimized, "segfaults on BOLT instrumented binaries") | ||
def test_init_python_env(self): | ||
preconfig = { | ||
'allocator': ALLOCATOR_FOR_CONFIG, | ||
@@ -1772,6 +1775,7 @@ def test_init_set_config(self): | ||
self.check_all_configs("test_init_set_config", config, | ||
api=API_ISOLATED) | ||
|
||
+ @unittest.skip("segfaults on BOLT instrumented binaries") | ||
+ @unittest.skipIf(support.check_bolt_optimized, "segfaults on BOLT instrumented binaries") | ||
def test_initconfig_api(self): | ||
preconfig = { | ||
'configure_locale': True, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,20 @@ | ||
diff --git a/Lib/test/test_embed.py b/Lib/test/test_embed.py | ||
index 13713cf37b8..ba23880b15f 100644 | ||
index 13713cf37b8..40ee4837bfe 100644 | ||
--- a/Lib/test/test_embed.py | ||
+++ b/Lib/test/test_embed.py | ||
@@ -1615,6 +1615,7 @@ def test_getpath_abspath_win32(self): | ||
for (_, expected), result in zip(CASES, results): | ||
self.assertEqual(result, expected) | ||
|
||
+ @unittest.skip("segfaults on BOLT instrumented binaries") | ||
+ @unittest.skipIf(support.check_bolt_optimized, "segfaults on BOLT instrumented binaries") | ||
def test_global_pathconfig(self): | ||
# Test C API functions getting the path configuration: | ||
# | ||
@@ -1866,6 +1867,7 @@ def test_no_memleak(self): | ||
self.assertEqual(blocks, 0, out) | ||
|
||
|
||
+@unittest.skip("segfaults on BOLT instrumented binaries") | ||
+@unittest.skipIf(support.check_bolt_optimized, "segfaults on BOLT instrumented binaries") | ||
class StdPrinterTests(EmbeddingTestsMixin, unittest.TestCase): | ||
# Test PyStdPrinter_Type which is used by _PySys_SetPreliminaryStderr(): | ||
# "Set up a preliminary stderr printer until we have enough |