summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAntoine Pitrou <solipsis@pitrou.net>2013-08-16 19:02:02 (GMT)
committerAntoine Pitrou <solipsis@pitrou.net>2013-08-16 19:02:02 (GMT)
commit05eafa887b8c8046c0045f53eac1383caaed2b6e (patch)
treeaf40f90c889fecfb1e9a5c57e43c940fa08f2b6a
parent95b21460ee7ae6b9b52753cf2509d439bd6a0476 (diff)
downloadcpython-05eafa887b8c8046c0045f53eac1383caaed2b6e.zip
cpython-05eafa887b8c8046c0045f53eac1383caaed2b6e.tar.gz
cpython-05eafa887b8c8046c0045f53eac1383caaed2b6e.tar.bz2
Make test.support.reap_threads() faster
-rw-r--r--Lib/test/support/__init__.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/test/support/__init__.py b/Lib/test/support/__init__.py
index 2867688..59f7fcc 100644
--- a/Lib/test/support/__init__.py
+++ b/Lib/test/support/__init__.py
@@ -1750,12 +1750,12 @@ def threading_setup():
def threading_cleanup(*original_values):
if not _thread:
return
- _MAX_COUNT = 10
+ _MAX_COUNT = 100
for count in range(_MAX_COUNT):
values = _thread._count(), threading._dangling
if values == original_values:
break
- time.sleep(0.1)
+ time.sleep(0.01)
gc_collect()
# XXX print a warning in case of failure?