Skip to content

Commit 9d5c203

Browse files
committed
Revert "test_peg_generator and test_freeze require cpu (python#108386)"
This reverts commit 7a6cc3e.
1 parent 852b6a2 commit 9d5c203

File tree

3 files changed

+10
-5
lines changed

3 files changed

+10
-5
lines changed

Lib/test/test_peg_generator/__init__.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,10 @@
44
from test.support import load_package_tests
55

66

7-
# Creating a virtual environment and building C extensions is slow
8-
support.requires('cpu')
7+
if support.check_sanitizer(address=True, memory=True):
8+
# gh-90791: Skip the test because it is too slow when Python is built
9+
# with ASAN/MSAN: between 5 and 20 minutes on GitHub Actions.
10+
raise unittest.SkipTest("test too slow on ASAN/MSAN build")
911

1012

1113
# Load all tests in package

Lib/test/test_tools/__init__.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,12 @@
77
from test.support import import_helper
88

99

10+
if support.check_sanitizer(address=True, memory=True):
11+
# gh-90791: Skip the test because it is too slow when Python is built
12+
# with ASAN/MSAN: between 5 and 20 minutes on GitHub Actions.
13+
raise unittest.SkipTest("test too slow on ASAN/MSAN build")
14+
15+
1016
if not support.has_subprocess_support:
1117
raise unittest.SkipTest("test module requires subprocess")
1218

Lib/test/test_tools/test_freeze.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,6 @@
1818
class TestFreeze(unittest.TestCase):
1919

2020
def test_freeze_simple_script(self):
21-
# Building Python is slow
22-
support.requires('cpu')
23-
2421
script = textwrap.dedent("""
2522
import sys
2623
print('running...')

0 commit comments

Comments
 (0)