[Python-checkins] cpython (3.2): test_asyncore: wait explicitly for a thread termination (this dangling thread

charles-francois.natali python-checkins at python.org
Sun Jan 13 14:15:56 CET 2013


http://hg.python.org/cpython/rev/d55a06f7ccbf
changeset: 81474:d55a06f7ccbf
branch: 3.2
parent: 81459:20065626c0b5
user: Charles-François Natali <cf.natali at gmail.com>
date: Sun Jan 13 13:56:52 2013 +0100
summary:
 test_asyncore: wait explicitly for a thread termination (this dangling thread
could be the cause of a random failure).
files:
 Lib/test/test_asyncore.py | 1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/Lib/test/test_asyncore.py b/Lib/test/test_asyncore.py
--- a/Lib/test/test_asyncore.py
+++ b/Lib/test/test_asyncore.py
@@ -738,6 +738,7 @@
 server = TCPServer()
 t = threading.Thread(target=lambda: asyncore.loop(timeout=0.1, count=500))
 t.start()
+ self.addCleanup(t.join)
 
 for x in range(20):
 s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list

AltStyle によって変換されたページ (->オリジナル) /