]> granicus.if.org Git - python/commitdiff
Relax test timing (bpo-29861) to avoid sporadic failures (#1120) (#1472)
authorVictor Stinner <victor.stinner@gmail.com>
Fri, 5 May 2017 07:47:11 +0000 (09:47 +0200)
committerGitHub <noreply@github.com>
Fri, 5 May 2017 07:47:11 +0000 (09:47 +0200)
(cherry picked from commit 685cdb9acc3fca04a9897d88b89771ddfd50e772)

Lib/test/test_multiprocessing.py

index 163c42f1d10a17ced98084cbe4d0601db3e704df..8cc4f5423acd51a37a6b31e8c24178bad2374a29 100644 (file)
@@ -1290,6 +1290,7 @@ class _TestPool(BaseTestCase):
         self.pool.map(identity, objs)
 
         del objs
+        time.sleep(DELTA)  # let threaded cleanup code run
         self.assertEqual(set(wr() for wr in refs), {None})
         # With a process pool, copies of the objects are returned, check
         # they were released too.