Skip to content

Commit 99645f5

Browse files
committed
Check ps -p availability in process title test
1 parent 8fd79d3 commit 99645f5

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

sapi/cli/tests/cli_process_title_unix.phpt

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,12 @@ if (PHP_SAPI !== "cli")
77
if (!PHP_CLI_PROCESS_TITLE)
88
die("skip process title not available (disabled or unsupported)");
99
if (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN')
10-
die("skip");
10+
die("skip Not for Windows");
11+
12+
exec("ps -p 1", $output, $exit_code);
13+
if ($exit_code !== 0) {
14+
die("skip ps -p is not available");
15+
}
1116
?>
1217
--FILE--
1318
<?php

0 commit comments

Comments
 (0)