From 7a7ce2c8b4246fdfc8bd42dff781298edeb54dd2 Mon Sep 17 00:00:00 2001 From: Nicolas Grekas Date: Thu, 5 Sep 2024 18:13:22 +0200 Subject: [PATCH 1/2] Don't use is_resource() on non-streams --- Terminal.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Terminal.php b/Terminal.php index b91e8afc5..948ced4ad 100644 --- a/Terminal.php +++ b/Terminal.php @@ -158,8 +158,7 @@ private static function readFromProcess(string $command): ?string $cp = \function_exists('sapi_windows_cp_set') ? sapi_windows_cp_get() : 0; - $process = proc_open($command, $descriptorspec, $pipes, null, null, ['suppress_errors' => true]); - if (!\is_resource($process)) { + if (!$process = proc_open($command, $descriptorspec, $pipes, null, null, ['suppress_errors' => true])) { return null; } From 5b5a0aa66e3296e303e22490f90f521551835a83 Mon Sep 17 00:00:00 2001 From: Alexandre Daubois Date: Fri, 20 Sep 2024 09:50:07 +0200 Subject: [PATCH 2/2] Mutate remaining data providers to static ones --- Tests/Formatter/OutputFormatterTest.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Tests/Formatter/OutputFormatterTest.php b/Tests/Formatter/OutputFormatterTest.php index 21905f475..f65e0a15d 100644 --- a/Tests/Formatter/OutputFormatterTest.php +++ b/Tests/Formatter/OutputFormatterTest.php @@ -200,7 +200,7 @@ public static function provideInlineStyleOptionsCases() ]; } - public function provideInlineStyleTagsWithUnknownOptions() + public static function provideInlineStyleTagsWithUnknownOptions() { return [ ['', 'abc'],