Skip to content

Commit

Permalink
[mb tests] to ignore expected uncertainty
Browse files Browse the repository at this point in the history
- just Unittest Orient Programming.
  • Loading branch information
NyaCl committed Dec 17, 2024
1 parent fdf35fe commit 857903f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tests/test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,7 @@ async def test_call_later(self) -> None:
begin = aio.get_event_loop().time()
await aio.sleep(5)
end = self.timestamps[0]
assert isclose(end - begin, 5.01, abs_tol=0.01)
assert isclose(end - begin, 5.01, abs_tol=0.011)

# may not meaningful, just refer `test_call_later` is also OK.
async def test_call_at(self) -> None:
Expand All @@ -270,7 +270,7 @@ async def test_async_later(self) -> None:
begin = aio.get_event_loop().time()
await async_later(self.afoo(), 5)
end = self.timestamps[0]
assert isclose(end - begin, 5.01, abs_tol=0.01)
assert isclose(end - begin, 5.01, abs_tol=0.011)

# just refer `test_async_later`.
async def test_async_at(self) -> None:
Expand All @@ -289,7 +289,7 @@ async def test_async_interval(self) -> None:
assert isclose(
self.timestamps[i] - self.timestamps[i - 1],
1.01,
abs_tol=0.01
abs_tol=0.011
)
i += 1
assert t.done()

0 comments on commit 857903f

Please sign in to comment.