@@ -22,7 +22,7 @@ class FlockMutexTest extends TestCase
2222 private $ mutex ;
2323
2424 /**
25- * @var resource
25+ * @var string
2626 */
2727 private $ file ;
2828
@@ -31,7 +31,7 @@ protected function setUp(): void
3131 parent ::setUp ();
3232
3333 $ this ->file = tempnam (sys_get_temp_dir (), 'flock- ' );
34- $ this ->mutex = Liberator::liberate (new FlockMutex (fopen ($ this ->file , 'r ' ), 1 ));
34+ $ this ->mutex = Liberator::liberate (new FlockMutex (fopen ($ this ->file , 'r ' ), 1 )); // @phpstan-ignore-line
3535 }
3636
3737 protected function tearDown (): void
@@ -46,10 +46,10 @@ protected function tearDown(): void
4646 */
4747 public function testCodeExecutedOutsideLockIsNotThrown (int $ strategy )
4848 {
49- $ this ->mutex ->strategy = $ strategy ;
49+ $ this ->mutex ->strategy = $ strategy ; // @phpstan-ignore-line
5050
5151 $ this ->assertTrue ($ this ->mutex ->synchronized (function (): bool {
52- usleep (1.1e6 );
52+ usleep (1100 * 1000 );
5353
5454 return true ;
5555 }));
@@ -66,7 +66,7 @@ public function testTimeoutOccurs(int $strategy)
6666 $ another_resource = fopen ($ this ->file , 'r ' );
6767 flock ($ another_resource , LOCK_EX );
6868
69- $ this ->mutex ->strategy = $ strategy ;
69+ $ this ->mutex ->strategy = $ strategy ; // @phpstan-ignore-line
7070
7171 try {
7272 $ this ->mutex ->synchronized (
@@ -94,7 +94,7 @@ public function testNoTimeoutWaitsForever()
9494 $ another_resource = fopen ($ this ->file , 'r ' );
9595 flock ($ another_resource , LOCK_EX );
9696
97- $ this ->mutex ->strategy = FlockMutex::STRATEGY_BLOCK ;
97+ $ this ->mutex ->strategy = FlockMutex::STRATEGY_BLOCK ; // @phpstan-ignore-line
9898
9999 $ timebox = new PcntlTimeout (1 );
100100 $ timebox ->timeBoxed (function () {
0 commit comments