Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gevent
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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gevent
Commits
7e6ed0ae
Commit
7e6ed0ae
authored
Apr 06, 2017
by
Jason Madden
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix flaky test.
parent
47a31554
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
25 additions
and
1 deletion
+25
-1
src/greentest/greentest.py
src/greentest/greentest.py
+1
-0
src/greentest/test__socket_dns.py
src/greentest/test__socket_dns.py
+24
-1
No files found.
src/greentest/greentest.py
View file @
7e6ed0ae
...
...
@@ -591,6 +591,7 @@ class GenericWaitTestCase(_DelayWaitMixin, TestCase):
# and subject to jitter
_default_delay_max_adj
=
1.5
@
ignores_leakcheck
# waiting checks can be very sensitive to timing
def
test_returns_none_after_timeout
(
self
):
result
=
self
.
_wait_and_check
()
# join and wait simply return after timeout expires
...
...
src/greentest/test__socket_dns.py
View file @
7e6ed0ae
...
...
@@ -535,7 +535,30 @@ class TestInterrupted_gethostbyname(greentest.GenericWaitTestCase):
raise
AssertionError
(
'Timeout was not raised'
)
def
cleanup
(
self
):
# Depending on timing, this can raise:
# (This suddenly started happening on Apr 6 2016; www.x1000000.com
# is apparently no longer around)
# File "test__socket_dns.py", line 538, in cleanup
# gevent.get_hub().threadpool.join()
# File "/home/travis/build/gevent/gevent/src/gevent/threadpool.py", line 108, in join
# sleep(delay)
# File "/home/travis/build/gevent/gevent/src/gevent/hub.py", line 169, in sleep
# hub.wait(loop.timer(seconds, ref=ref))
# File "/home/travis/build/gevent/gevent/src/gevent/hub.py", line 651, in wait
# result = waiter.get()
# File "/home/travis/build/gevent/gevent/src/gevent/hub.py", line 899, in get
# return self.hub.switch()
# File "/home/travis/build/gevent/gevent/src/greentest/greentest.py", line 520, in switch
# return _original_Hub.switch(self, *args)
# File "/home/travis/build/gevent/gevent/src/gevent/hub.py", line 630, in switch
# return RawGreenlet.switch(self)
# gaierror: [Errno -2] Name or service not known
try
:
gevent
.
get_hub
().
threadpool
.
join
()
except
Exception
:
# pylint:disable=broad-except
import
traceback
traceback
.
print_exc
()
# class TestInterrupted_getaddrinfo(greentest.GenericWaitTestCase):
...
...
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