Commit 83bc3dd9 authored by Jason Madden's avatar Jason Madden

Tweak timing.

parent c456b6ca
......@@ -64,7 +64,9 @@ class TimeAssertMixin(object):
start = time()
yield
elapsed = time() - start
self.assertTimeWithinRange(elapsed, expected - fuzzy, expected + fuzzy)
self.assertTrue(
expected - fuzzy <= elapsed <= expected + fuzzy,
'Expected: %r; elapsed: %r; fuzzy %r' % (expected, elapsed, fuzzy))
def runs_in_no_time(
self,
......
......@@ -6,7 +6,8 @@ import gevent.core
from gevent.event import Event
from gevent.testing.testcase import TimeAssertMixin
from gevent.testing.timing import SMALL_TICK
SMALL_TICK = 0.05
# setting up signal does not affect join()
gevent.signal(1, lambda: None) # wouldn't work on windows
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment