@@ -107,13 +107,13 @@ public function __destruct()
107
107
}
108
108
}
109
109
110
- public function globalListenerDisabled ()
110
+ public function globalListenerDisabled (): void
111
111
{
112
112
self ::$ globallyEnabled = false ;
113
113
$ this ->state = -1 ;
114
114
}
115
115
116
- public function startTestSuite ($ suite )
116
+ public function startTestSuite ($ suite ): void
117
117
{
118
118
$ suiteName = $ suite ->getName ();
119
119
@@ -188,14 +188,14 @@ public function startTestSuite($suite)
188
188
}
189
189
}
190
190
191
- public function addSkippedTest ($ test , \Exception $ e , $ time )
191
+ public function addSkippedTest ($ test , \Exception $ e , $ time ): void
192
192
{
193
193
if (0 < $ this ->state ) {
194
194
$ this ->isSkipped [\get_class ($ test )][$ test ->getName ()] = 1 ;
195
195
}
196
196
}
197
197
198
- public function startTest ($ test )
198
+ public function startTest ($ test ): void
199
199
{
200
200
if (-2 < $ this ->state && $ test instanceof TestCase) {
201
201
// This event is triggered before the test is re-run in isolation
@@ -242,7 +242,7 @@ public function startTest($test)
242
242
}
243
243
}
244
244
245
- public function endTest ($ test , $ time )
245
+ public function endTest ($ test , $ time ): void
246
246
{
247
247
if ($ file = getenv ('SYMFONY_EXPECTED_DEPRECATIONS_SERIALIZE ' )) {
248
248
putenv ('SYMFONY_EXPECTED_DEPRECATIONS_SERIALIZE ' );
@@ -338,15 +338,10 @@ public static function handleError($type, $msg, $file, $line, $context = [])
338
338
}
339
339
self ::$ gatheredDeprecations [] = $ msg ;
340
340
341
- return null ;
341
+ return true ;
342
342
}
343
343
344
- /**
345
- * @param TestCase $test
346
- *
347
- * @return bool
348
- */
349
- private function willBeIsolated ($ test )
344
+ private function willBeIsolated (TestCase $ test ): bool
350
345
{
351
346
if ($ test ->isInIsolation ()) {
352
347
return false ;
@@ -355,6 +350,6 @@ private function willBeIsolated($test)
355
350
$ r = new \ReflectionProperty ($ test , 'runTestInSeparateProcess ' );
356
351
$ r ->setAccessible (true );
357
352
358
- return $ r ->getValue ($ test );
353
+ return $ r ->getValue ($ test ) ?? false ;
359
354
}
360
355
}
0 commit comments