From a75ac9b4984c52da857c4bd78b9aaacf995c9cd2 Mon Sep 17 00:00:00 2001 From: Paul Tarjan Date: Fri, 21 Jun 2013 23:34:18 -0700 Subject: [PATCH] remove duplciated content I think you double imported this. It is all in `lwp.php` --- hphp/test/slow/ext_process/ext_process.php | 94 ------------------- .../slow/ext_process/ext_process.php.expect | 38 -------- 2 files changed, 132 deletions(-) diff --git a/hphp/test/slow/ext_process/ext_process.php b/hphp/test/slow/ext_process/ext_process.php index dfaf3af4e..15a0e056f 100644 --- a/hphp/test/slow/ext_process/ext_process.php +++ b/hphp/test/slow/ext_process/ext_process.php @@ -74,97 +74,3 @@ if ($pid == 0) { pcntl_waitpid(0, $status); VS(pcntl_wtermsig($status), 0); -$output = shell_exec("echo hello"); -VS($output, "hello\n"); - -chdir("/tmp/"); -VS(shell_exec("/bin/pwd"), "/tmp\n"); - -pcntl_signal_dispatch(); - -$last_line = exec("echo hello; echo world;", $output, $ret); -VS($output, array("hello", "world")); -VS($last_line, "world"); -VS($ret, 0); - -chdir("/tmp/"); -VS(exec("/bin/pwd"), "/tmp"); - -echo "heh\n"; - -passthru("echo hello; echo world;", $ret); -VS($ret, 0); - -chdir("/tmp/"); -passthru("/bin/pwd"); - -$last_line = system("echo hello; echo world;", $ret); -VS($last_line, "world"); -VS($ret, 0); - -chdir("/tmp/"); -VS(system("/bin/pwd"), "/tmp"); - -$descriptorspec = - array(array("pipe", "r"), - array("pipe", "w"), - array("file", "/tmp/error-output.txt", "a")); - -putenv("inherit_me=please"); -$process = proc_open('echo $inherit_me', $descriptorspec, $pipes); -VERIFY($process != false); - -fpassthru($pipes[1]); - -VS(proc_close($process), 0); - -// Ensure that PATH makes it through too -$process = proc_open('echo $PATH', $descriptorspec, $pipes); -VERIFY($process != false); - -VERIFY(strlen(fgets($pipes[1])) > 2); - -VS(proc_close($process), 0); - -$descriptorspec = - array(array("pipe", "r"), - array("pipe", "w"), - array("file", "/tmp/error-output.txt", "a")); -$cwd = "/tmp"; -$env = array("some_option" => "aeiou"); - -$process = proc_open("php", $descriptorspec, $pipes, $cwd, $env); -VERIFY($process != false); - -fprintf($pipes[0], ""); -fclose($pipes[0]); -fpassthru($pipes[1]); -VS(proc_close($process), 0); - -$descriptorspec = - array(array("pipe", "r"), - array("pipe", "w"), - array("file", "/tmp/error-output.txt", "a")); -$process = proc_open('php', $descriptorspec, $pipes); -VERIFY($process != false); -VERIFY(proc_terminate($process)); -// still need to close it, not to leave a zombie behind -proc_close($process); - -$process = proc_open('php', $descriptorspec, $pipes); -VERIFY($process != false); -$ret = proc_get_status($process); -VS($ret['command'], 'php'); -VERIFY($ret['pid'] > 0); -VERIFY($ret['running']); -VERIFY(!$ret['signaled']); -VS($ret['exitcode'], -1); -VS($ret['termsig'], 0); -VS($ret['stopsig'], 0); -proc_close($process); - -VERIFY(proc_nice(0)); - -VS(escapeshellarg("\""), "'\"'"); - -VS(escapeshellcmd("perl \""), "perl \\\""); diff --git a/hphp/test/slow/ext_process/ext_process.php.expect b/hphp/test/slow/ext_process/ext_process.php.expect index 8bdb6b05b..c410f217b 100644 --- a/hphp/test/slow/ext_process/ext_process.php.expect +++ b/hphp/test/slow/ext_process/ext_process.php.expect @@ -8,41 +8,3 @@ bool(true) bool(true) bool(true) bool(true) -bool(true) -bool(true) -bool(true) -bool(true) -bool(true) -bool(true) -heh -hello -world -bool(true) -/tmp -hello -world -bool(true) -bool(true) -/tmp -bool(true) -bool(true) -please -bool(true) -bool(true) -bool(true) -bool(true) -bool(true) -aeioubool(true) -bool(true) -bool(true) -bool(true) -bool(true) -bool(true) -bool(true) -bool(true) -bool(true) -bool(true) -bool(true) -bool(true) -bool(true) -bool(true)