From 99645f5352b5dc9faaece36f606edfff5f7a7460 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Wed, 5 Aug 2020 12:23:27 +0200 Subject: Check ps -p availability in process title test --- sapi/cli/tests/cli_process_title_unix.phpt | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'sapi/cli') diff --git a/sapi/cli/tests/cli_process_title_unix.phpt b/sapi/cli/tests/cli_process_title_unix.phpt index d6e49a2221..166cb79ad3 100644 --- a/sapi/cli/tests/cli_process_title_unix.phpt +++ b/sapi/cli/tests/cli_process_title_unix.phpt @@ -7,7 +7,12 @@ if (PHP_SAPI !== "cli") if (!PHP_CLI_PROCESS_TITLE) die("skip process title not available (disabled or unsupported)"); if (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN') - die("skip"); + die("skip Not for Windows"); + +exec("ps -p 1", $output, $exit_code); +if ($exit_code !== 0) { + die("skip ps -p is not available"); +} ?> --FILE--