From: Stanislav Malyshev Date: Mon, 11 May 2015 06:33:44 +0000 (-0700) Subject: Update tests X-Git-Tag: php-5.4.41~2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=634aa0a2dbf8ec5e6fabb4ee01c6d1355ba7ee67;p=php Update tests --- diff --git a/ext/standard/tests/dir/dir_variation1.phpt b/ext/standard/tests/dir/dir_variation1.phpt index abb4719504..fff04ba8f9 100644 --- a/ext/standard/tests/dir/dir_variation1.phpt +++ b/ext/standard/tests/dir/dir_variation1.phpt @@ -8,7 +8,7 @@ if (substr(PHP_OS, 0, 3) == 'WIN') { ?> --FILE-- path = $path; @@ -73,7 +73,7 @@ $inputs = array( false, TRUE, FALSE, - + // empty data /*16*/ "", '', @@ -83,7 +83,7 @@ $inputs = array( /*19*/ "$path", 'string', $heredoc, - + // object data /*22*/ new classA($path), @@ -216,7 +216,7 @@ bool(false) -- Iteration 18 -- -Warning: opendir() expects parameter 1 to be string, array given in %s on line %d +Warning: opendir() expects parameter 1 to be a valid path, array given in %s on line %d NULL -- Iteration 19 -- @@ -243,6 +243,6 @@ bool(false) -- Iteration 25 -- -Warning: opendir() expects parameter 1 to be string, resource given in %s on line %d +Warning: opendir() expects parameter 1 to be a valid path, resource given in %s on line %d NULL ===DONE=== diff --git a/ext/standard/tests/dir/opendir_variation1.phpt b/ext/standard/tests/dir/opendir_variation1.phpt index 8d195e1e62..cb4d543f72 100644 --- a/ext/standard/tests/dir/opendir_variation1.phpt +++ b/ext/standard/tests/dir/opendir_variation1.phpt @@ -9,7 +9,7 @@ if (substr(PHP_OS, 0, 3) == 'WIN') { --FILE-- path = $path; @@ -73,7 +73,7 @@ $inputs = array( false, TRUE, FALSE, - + // empty data /*16*/ "", '', @@ -83,7 +83,7 @@ $inputs = array( /*19*/ "$path", 'string', $heredoc, - + // object data /*22*/ new classA($path), @@ -194,7 +194,7 @@ bool(false) -- Iteration 18 -- -Warning: opendir() expects parameter 1 to be string, array given in %s on line %d +Warning: opendir() expects parameter 1 to be a valid path, array given in %s on line %d NULL -- Iteration 19 -- @@ -219,6 +219,6 @@ bool(false) -- Iteration 25 -- -Warning: opendir() expects parameter 1 to be string, resource given in %s on line %d +Warning: opendir() expects parameter 1 to be a valid path, resource given in %s on line %d NULL ===DONE=== diff --git a/ext/standard/tests/file/mkdir_rmdir_variation2.phpt b/ext/standard/tests/file/mkdir_rmdir_variation2.phpt index 14dd361e07..24dfc96ac9 100644 --- a/ext/standard/tests/file/mkdir_rmdir_variation2.phpt +++ b/ext/standard/tests/file/mkdir_rmdir_variation2.phpt @@ -68,7 +68,7 @@ bool(false) Warning: mkdir() expects parameter 1 to be a valid path, string given in %s on line %d bool(false) -Warning: rmdir(%s): No such file or directory in %s on line %d +Warning: rmdir() expects parameter 1 to be a valid path, string given in %s on line %d bool(false) *** Testing mkdir() with miscelleneous input *** diff --git a/ext/standard/tests/file/tempnam_variation3-win32.phpt b/ext/standard/tests/file/tempnam_variation3-win32.phpt index fb457cb6ab..cc8194afa3 100644 --- a/ext/standard/tests/file/tempnam_variation3-win32.phpt +++ b/ext/standard/tests/file/tempnam_variation3-win32.phpt @@ -22,9 +22,9 @@ if (!mkdir($file_path)) { $file_path = realpath($file_path); -/* An array of prefixes */ +/* An array of prefixes */ $names_arr = array( - /* Valid args (casting)*/ + /* Valid args (casting)*/ -1, TRUE, FALSE, @@ -32,17 +32,17 @@ $names_arr = array( "", " ", "\0", - /* Invalid args */ + /* Invalid args */ array(), - /* Valid args*/ + /* Valid args*/ /* prefix with path separator of a non existing directory*/ - "/no/such/file/dir", + "/no/such/file/dir", "php/php" ); $res_arr = array( - /* Invalid args */ + /* Invalid args */ true, true, true, @@ -53,7 +53,7 @@ $res_arr = array( false, /* prefix with path separator of a non existing directory*/ - true, + true, true ); @@ -72,7 +72,7 @@ for( $i=0; $i "; printf("%o", fileperms($file_name) ); echo "\n"; - + echo "File created in => "; $file_dir = dirname($file_name); - + if ($file_dir == sys_get_temp_dir()) { echo "temp dir\n"; } @@ -61,7 +61,7 @@ for( $i=0; $i %s/%s File permissions are => 100600 File created in => directory specified -- Iteration 6 -- -File name is => %s/%s -File permissions are => 100600 -File created in => directory specified + +Warning: tempnam() expects parameter 2 to be a valid path, string given in %s on line %d +-- File is not created -- + +Warning: unlink(): %s in %s on line %d -- Iteration 7 -- -Warning: tempnam() expects parameter 2 to be string, array given in %s on line %d +Warning: tempnam() expects parameter 2 to be a valid path, array given in %s on line %d -- File is not created -- Warning: unlink(): %s in %s on line %d diff --git a/ext/standard/tests/general_functions/include_path.phpt b/ext/standard/tests/general_functions/include_path.phpt index 039230784d..8b6626fbc8 100644 --- a/ext/standard/tests/general_functions/include_path.phpt +++ b/ext/standard/tests/general_functions/include_path.phpt @@ -41,7 +41,7 @@ var_dump(get_include_path()); echo "Done\n"; ?> ---EXPECTF-- +--EXPECTF-- string(1) "." Warning: get_include_path() expects exactly 0 parameters, 1 given in %s on line %d @@ -67,7 +67,7 @@ string(1) "." NULL string(1) "." -Warning: set_include_path() expects parameter 1 to be string, array given in %s on line %d +Warning: set_include_path() expects parameter 1 to be a valid path, array given in %s on line %d NULL string(1) "." NULL