Skip to content

Commit

Permalink
updating test_timeout to have a larger time margin so that the test d…
Browse files Browse the repository at this point in the history
…oes not fail on busy systems. closes #129
  • Loading branch information
Andrew Moffat committed Feb 14, 2013
1 parent 8c17049 commit 755b977
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test.py
Original file line number Diff line number Diff line change
Expand Up @@ -1190,7 +1190,7 @@ def test_timeout(self):
sh.sleep(sleep_for).wait()
elapsed = time() - started

self.assertTrue(abs(elapsed - sleep_for) < 0.1)
self.assertTrue(abs(elapsed - sleep_for) < 0.5)

# now make sure that killing early makes the process take less time
sleep_for = 3
Expand All @@ -1199,7 +1199,7 @@ def test_timeout(self):
try: sh.sleep(sleep_for, _timeout=timeout).wait()
except sh.SignalException_9: pass
elapsed = time() - started
self.assertTrue(abs(elapsed - timeout) < 0.1)
self.assertTrue(abs(elapsed - timeout) < 0.5)


def test_binary_pipe(self):
Expand Down

0 comments on commit 755b977

Please sign in to comment.