Skip to content

Commit

Permalink
Fix Time Test failing for no reason
Browse files Browse the repository at this point in the history
Signed-off-by: Benjamin Brahmer <[email protected]>
  • Loading branch information
Grotax committed Dec 18, 2023
1 parent 373706e commit 3baa3d6
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tests/Unit/Utility/TimeTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@ public function testMicroTime(): void
{
$cur = microtime(true) * 1000000;

// required because the test fails otherwise from time to time
sleep(1);

$time = new Time();
$result = (float) $time->getMicroTime();
$this->assertTrue($result > $cur);
Expand Down

0 comments on commit 3baa3d6

Please sign in to comment.