Download src/php/php-src/ext/pcntl/tests/pcntl_exec_2.phpt from meddyrat/dis-bench: direct link, hf CLI and curl.
- Browser
- Download file 503 Bytes
-
https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/ext/pcntl/tests/pcntl_exec_2.phpt
- Command line
-
hf download hf://datasets/meddyrat/dis-bench/src/php/php-src/ext/pcntl/tests/pcntl_exec_2.phpt
-
curl -L -o pcntl_exec_2.phpt https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/ext/pcntl/tests/pcntl_exec_2.phpt
503 Bytes
| --TEST-- | |
| pcntl_exec() 2 | |
| --EXTENSIONS-- | |
| pcntl | |
| --SKIPIF-- | |
| if (!getenv("TEST_PHP_EXECUTABLE") || !is_executable(getenv("TEST_PHP_EXECUTABLE"))) die("skip TEST_PHP_EXECUTABLE not set"); | |
| --FILE-- | |
| if (getenv("PCNTL_EXEC_TEST_IS_CHILD")) { | |
| var_dump(getenv("FOO")); | |
| exit; | |
| } | |
| echo "ok\n"; | |
| pcntl_exec(getenv("TEST_PHP_EXECUTABLE"), array('-n', __FILE__), array( | |
| "PCNTL_EXEC_TEST_IS_CHILD" => "1", | |
| "FOO" => "BAR", | |
| 1 => "long") | |
| ); | |
| echo "nok\n"; | |
| --EXPECT-- | |
| ok | |
| string(3) "BAR" | |