Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
45fdb457
Commit
45fdb457
authored
Apr 04, 2011
by
Antoine Pitrou
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Try to fix sporadic failure in test_thread/test_threading
parent
b35f29a0
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
1 deletion
+7
-1
Lib/test/lock_tests.py
Lib/test/lock_tests.py
+7
-1
No files found.
Lib/test/lock_tests.py
View file @
45fdb457
...
...
@@ -141,6 +141,12 @@ class BaseLockTests(BaseTestCase):
# We run many threads in the hope that existing threads ids won't
# be recycled.
Bunch
(
f
,
15
).
wait_for_finished
()
if
len
(
threading
.
enumerate
())
!=
n
:
# There is a small window during which a Thread instance's
# target function has finished running, but the Thread is still
# alive and registered. Avoid spurious failures by waiting a
# bit more (seen on a buildbot).
time
.
sleep
(
0.4
)
self
.
assertEqual
(
n
,
len
(
threading
.
enumerate
()))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment