aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Lib/test/test_exceptions.py
diff options
context:
space:
mode:
authorErlend E. Aasland <erlend@python.org>2024-04-08 14:45:25 +0200
committerGitHub <noreply@github.com>2024-04-08 14:45:25 +0200
commitca62ffd1a5ef41401abceddfd171c76c68825a35 (patch)
treebc5ece1694f0d99642446844f74be11ebd7e53b0 /Lib/test/test_exceptions.py
parent9a12f5d1c19dee1f89684be776680aeaf117be5b (diff)
downloadcpython-ca62ffd1a5ef41401abceddfd171c76c68825a35.tar.gz
cpython-ca62ffd1a5ef41401abceddfd171c76c68825a35.zip
gh-116303: Skip tests if C recursion limit is unavailable (GH-117368)
The test suite fetches the C recursion limit from the _testcapi extension module. Test extension modules can be disabled using the --disable-test-modules configure option.
Diffstat (limited to 'Lib/test/test_exceptions.py')
-rw-r--r--Lib/test/test_exceptions.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/test/test_exceptions.py b/Lib/test/test_exceptions.py
index 6ad6acc6156..36fd89dbb88 100644
--- a/Lib/test/test_exceptions.py
+++ b/Lib/test/test_exceptions.py
@@ -1424,7 +1424,7 @@ class ExceptionTests(unittest.TestCase):
next(generator)
recursionlimit = sys.getrecursionlimit()
try:
- recurse(support.EXCEEDS_RECURSION_LIMIT)
+ recurse(support.exceeds_recursion_limit())
finally:
sys.setrecursionlimit(recursionlimit)
print('Done.')