Skip to content

Commit 60a0933

Browse files
committed
Clean up code
1 parent cd33b5c commit 60a0933

File tree

1 file changed

+3
-11
lines changed

1 file changed

+3
-11
lines changed

tests/Integration/IntegrationTestCase.php

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,9 @@ public static function setUpBeforeClass(): void
4141
}
4242

4343
fclose($process);
44-
$throwInsteadOfKill = false;
45-
if ($throwInsteadOfKill) {
44+
45+
$throwOnBusyPort = false;
46+
if ($throwOnBusyPort) {
4647
throw new RuntimeException(sprintf('Port 8080 is already in use. (PID %s)', $pid));
4748
} else {
4849
// Kill the process using the port
@@ -118,15 +119,6 @@ public static function setUpTestRunner(): void
118119
{
119120
echo "\33[33mSetting up test runner...\33[0m This may take a while.\n";
120121

121-
// Turn php warnings into exceptions
122-
set_error_handler(function ($severity, $message, $file, $line) {
123-
if (! (error_reporting() & $severity)) {
124-
return;
125-
}
126-
127-
throw new RuntimeException($message);
128-
});
129-
130122
$archive = 'https://github.com/hydephp/hyde/archive/refs/heads/master.zip';
131123
$target = (self::getRunnerPath());
132124
if (file_exists($target)) {

0 commit comments

Comments
 (0)