import zend standard tests
[hiphop-php.git] / hphp / test / zend / bad / ext-standard-file / popen_pclose_error-win32-debug.php
blob6c72b96d7559f1cafd9004750e785b12d1cba148
1 <?php
2 /*
3 * Prototype: resource popen ( string command, string mode )
4 * Description: Opens process file pointer.
6 * Prototype: int pclose ( resource handle );
7 * Description: Closes process file pointer.
8 */
9 $file_path = dirname(__FILE__);
10 echo "*** Testing for error conditions ***\n";
11 var_dump( popen() ); // Zero Arguments
12 var_dump( popen("abc.txt") ); // Single Argument
13 var_dump( popen("abc.txt", "rw") ); // Invalid mode Argument
14 var_dump( pclose() );
15 $file_handle = fopen($file_path."/popen.tmp", "w");
16 var_dump( pclose($file_handle, $file_handle) );
17 pclose($file_handle);
18 var_dump( pclose(1) );
19 echo "\n--- Done ---";
20 ?><?php
21 $file_path = dirname(__FILE__);
22 unlink($file_path."/popen.tmp");