From 5a605660745d32a9b9f4208666889c702527208c Mon Sep 17 00:00:00 2001 From: Victor Stinner Date: Tue, 24 Sep 2024 22:36:45 +0200 Subject: [PATCH] gh-124402: Require cpu resource in test_super slow method (#124434) test___class___modification_multithreaded() now requires the 'cpu' test resource on a Free Threaded build. --- Lib/test/test_super.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Lib/test/test_super.py b/Lib/test/test_super.py index 3ffbe03f0c2f11..b0d1f12513d404 100644 --- a/Lib/test/test_super.py +++ b/Lib/test/test_super.py @@ -4,6 +4,7 @@ import threading import unittest from unittest.mock import patch +from test import support from test.support import import_helper, threading_helper @@ -513,6 +514,11 @@ def test___class___modification_multithreaded(self): This should be the case anyways as our test suite sets an audit hook. """ + + if support.Py_GIL_DISABLED: + # gh-124402: On a Free Threaded build, the test takes a few minutes + support.requires('cpu') + class Foo: pass