ENH(TST): relax test of sleep to "1" places from "2"

The reason is that internally it does round, so even 1.005 then would not
be equal to 1.  Making it spaces==1 should be sufficient for up to 1.05
i.e. we would allow 50ms "drift"
pull/707/head
Yaroslav Halchenko 2014-04-16 13:17:58 -04:00
parent d7087412bb
commit 5bafc61e48
1 changed files with 1 additions and 1 deletions

View File

@ -160,7 +160,7 @@ class Transmitter(TransmitterBase):
self.assertEqual(self.transm.proceed(["sleep", "1"]), (0, None))
t1 = time.time()
# Approx 1 second delay
self.assertAlmostEqual(t1 - t0, 1, places=2)
self.assertAlmostEqual(t1 - t0, 1, places=1)
def testAddJail(self):
jail2 = "TestJail2"