From 755b977b71ee0aed4b580ac383fe6ad41aa026a4 Mon Sep 17 00:00:00 2001 From: Andrew Moffat Date: Wed, 13 Feb 2013 21:37:50 -0600 Subject: [PATCH] updating test_timeout to have a larger time margin so that the test does not fail on busy systems. closes #129 --- test.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test.py b/test.py index 54b62dd9..ec2236b4 100644 --- a/test.py +++ b/test.py @@ -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 @@ -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):