From: Pierre Joye Date: Sat, 30 Jan 2010 17:56:00 +0000 (+0000) Subject: - cs X-Git-Tag: php-5.4.0alpha1~363 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=ef48a746fd066459f860e6c119c15afb667e69b7;p=php - cs --- diff --git a/ext/standard/tests/file/tempnam_variation7-win32.phpt b/ext/standard/tests/file/tempnam_variation7-win32.phpt index 5096934e03..2bc69dba53 100644 --- a/ext/standard/tests/file/tempnam_variation7-win32.phpt +++ b/ext/standard/tests/file/tempnam_variation7-win32.phpt @@ -17,50 +17,47 @@ if(substr(PHP_OS, 0, 3) != "WIN") echo "*** Testing tempnam() with invalid/non-existing directory names ***\n"; /* An array of names, which will be passed as a dir name */ $names_arr = array( - /* Invalid args */ - -1, - TRUE, - FALSE, - NULL, - "", - " ", - "\0", - array(), - - /* Non-existing dirs */ - "/no/such/file/dir", - "php" + /* Invalid args */ + -1, + TRUE, + FALSE, + NULL, + "", + " ", + "\0", + array(), + /* Non-existing dirs */ + "/no/such/file/dir", + "php" ); for( $i=0; $i "; + print($file_name); + echo "\n"; - if( file_exists($file_name) ){ + echo "File permissions are => "; + printf("%o", fileperms($file_name) ); + echo "\n"; - echo "File name is => "; - print($file_name); - echo "\n"; + echo "File created in => "; + $file_dir = dirname($file_name); + if (realpath($file_dir) == realpath(sys_get_temp_dir()) || realpath($file_dir."\\") == realpath(sys_get_temp_dir())) { + echo "temp dir\n"; + } else { + echo "unknown location\n"; + } + } else { + echo "-- File is not created --\n"; + } - echo "File permissions are => "; - printf("%o", fileperms($file_name) ); - echo "\n"; - - echo "File created in => "; - $file_dir = dirname($file_name); - if (realpath($file_dir) == realpath(sys_get_temp_dir()) || realpath($file_dir."\\") == realpath(sys_get_temp_dir())) { - echo "temp dir\n"; - } - else { - echo "unknown location\n"; - } - } - else { - echo "-- File is not created --\n"; - } - - unlink($file_name); + unlink($file_name); } echo "\n*** Done ***\n";