[Python-checkins] cpython (merge 3.3 -> default): test_asyncore: wait explicitly for a thread termination (this dangling thread

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


http://hg.python.org/cpython/rev/aa26568e4739
changeset:   81477:aa26568e4739
parent:      81471:016953aabc47
parent:      81476:1719136ca357
user:        Charles-François Natali <cf.natali at gmail.com>
date:        Sun Jan 13 14:12:35 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 |  2 +-
  1 files changed, 1 insertions(+), 1 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
@@ -789,7 +789,7 @@
             t = threading.Thread(target=lambda: asyncore.loop(timeout=0.1,
                                                               count=500))
             t.start()
-
+            self.addCleanup(t.join)
 
             s = socket.socket(self.family, socket.SOCK_STREAM)
             s.settimeout(.2)

-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list