bpo-31731: test_io hangs with --huntrleaks: exclude it (GH-7459)
test_io hangs with --huntrleaks: exclude the test in regrtest.
diff --git a/Lib/test/regrtest.py b/Lib/test/regrtest.py
index d19be88..97ba2ad 100755
--- a/Lib/test/regrtest.py
+++ b/Lib/test/regrtest.py
@@ -577,6 +577,12 @@
nottests.add(arg)
args = []
+ if huntrleaks:
+ # FIXME: bpo-31731: test_io hangs with --huntrleaks
+ print("Warning: bpo-31731: test_io hangs with --huntrleaks: "
+ "exclude the test")
+ nottests.add('test_io')
+
display_header = (verbose or header or not (quiet or single or tests or args)) and (not pgo)
alltests = findtests(testdir, stdtests, nottests)
selected = tests or args or alltests