summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorCharles-François Natali <neologix@free.fr>2011-07-27 19:28:23 (GMT)
committerCharles-François Natali <neologix@free.fr>2011-07-27 19:28:23 (GMT)
commitfd96eb2a680e59ee21d42cb96ee85b6788501864 (patch)
tree8ac6e90ce279263591f637e0819ecb362c3530f3 /Lib
parent7a2f0c7802af898599d324f008a439c04ccb933a (diff)
parentd4d1d068dcf4e1aaf93772ccc0824207a21606e5 (diff)
downloadcpython-fd96eb2a680e59ee21d42cb96ee85b6788501864.zip
cpython-fd96eb2a680e59ee21d42cb96ee85b6788501864.tar.gz
cpython-fd96eb2a680e59ee21d42cb96ee85b6788501864.tar.bz2
Issue #11871: In test_threading.BarrierTests, bump the default barrier timeout
to avoid timing-dependent failures.
Diffstat (limited to 'Lib')
-rw-r--r--Lib/test/lock_tests.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/Lib/test/lock_tests.py b/Lib/test/lock_tests.py
index 7bcc436..12871c1 100644
--- a/Lib/test/lock_tests.py
+++ b/Lib/test/lock_tests.py
@@ -834,12 +834,12 @@ class BarrierTests(BaseTestCase):
"""
Test the barrier's default timeout
"""
- #create a barrier with a low default timeout
- barrier = self.barriertype(self.N, timeout=0.1)
+ # create a barrier with a low default timeout
+ barrier = self.barriertype(self.N, timeout=0.3)
def f():
i = barrier.wait()
if i == self.N // 2:
- # One thread is later than the default timeout of 0.1s.
+ # One thread is later than the default timeout of 0.3s.
time.sleep(1.0)
self.assertRaises(threading.BrokenBarrierError, barrier.wait)
self.run_threads(f)