We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
Conditions | 1 |
Paths | 1 |
Total Lines | 14 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php declare(strict_types=1); |
||
18 | public function test_update_cli() { |
||
19 | // Set the NPC_SCRIPT variable as if this were a CLI program |
||
20 | define('NPC_SCRIPT', true); |
||
21 | |||
22 | $time = Epoch::time(); |
||
23 | $microtime = Epoch::microtime(); |
||
24 | |||
25 | // Sleep 1 second to ensure that the integer time has incremented |
||
26 | sleep(1); |
||
27 | Epoch::update(); |
||
28 | |||
29 | // Make sure the times have changed |
||
30 | $this->assertNotEquals($time, Epoch::time()); |
||
31 | $this->assertNotEquals($microtime, Epoch::microtime()); |
||
32 | } |
||
52 |