summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_queue.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/test_queue.py')
-rw-r--r--Lib/test/test_queue.py10
1 files changed, 2 insertions, 8 deletions
diff --git a/Lib/test/test_queue.py b/Lib/test/test_queue.py
index e501669..35466c1 100644
--- a/Lib/test/test_queue.py
+++ b/Lib/test/test_queue.py
@@ -58,10 +58,7 @@ class BlockingTestMixin:
block_func)
return self.result
finally:
- thread.join(10) # make sure the thread terminates
- if thread.is_alive():
- self.fail("trigger function '%r' appeared to not return" %
- trigger_func)
+ support.join_thread(thread, 10) # make sure the thread terminates
# Call this instead if block_func is supposed to raise an exception.
def do_exceptional_blocking_test(self,block_func, block_args, trigger_func,
@@ -77,10 +74,7 @@ class BlockingTestMixin:
self.fail("expected exception of kind %r" %
expected_exception_class)
finally:
- thread.join(10) # make sure the thread terminates
- if thread.is_alive():
- self.fail("trigger function '%r' appeared to not return" %
- trigger_func)
+ support.join_thread(thread, 10) # make sure the thread terminates
if not thread.startedEvent.is_set():
self.fail("trigger thread ended but event never set")