Home
last modified time | relevance | path

Searched refs:rename (Results 1 – 25 of 71) sorted by relevance

123

/php-src/tests/security/
H A Dopen_basedir_rename.phpt9 test_open_basedir_before("rename");
11 var_dump(rename("../bad/bad.txt", "rename.txt"));
12 var_dump(rename(".././bad/bad.txt", "rename.txt"));
13 var_dump(rename("../bad/../bad/bad.txt", "rename.txt"));
14 var_dump(rename("./.././bad/bad.txt", "rename.txt"));
15 var_dump(rename($initdir."/test/bad/bad.txt", "rename.txt"));
17 test_open_basedir_after("rename");
25 *** Testing open_basedir configuration [rename] ***
32 Warning: rename(): open_basedir restriction in effect. File(../bad/bad.txt) is not within the allow…
35 Warning: rename(): open_basedir restriction in effect. File(.././bad/bad.txt) is not within the all…
[all …]
/php-src/ext/standard/tests/file/
H A Drename_variation8.phpt2 Test rename() function: variation
9 echo "\n*** Testing rename() on non-existing file ***\n";
15 var_dump( rename($src_name, $dest_name) );
21 // rename a existing dir to new name
22 echo "\n*** Testing rename() on existing directory ***\n";
26 var_dump( rename($dir_name, $new_dir_name) );
31 // try to rename an non_existing dir
35 var_dump( rename($non_existent_dir_name, $new_dir_name) );
47 *** Testing rename() on non-existing file ***
54 *** Testing rename() on existing directory ***
[all …]
H A Drename_variation8-win32.phpt2 Test rename() function: variation
9 echo "\n*** Testing rename() on non-existing file ***\n";
15 var_dump( rename($src_name, $dest_name) );
21 // rename a existing dir to new name
22 echo "\n*** Testing rename() on existing directory ***\n";
26 var_dump( rename($dir_name, $new_dir_name) );
31 // try to rename an non_existing dir
35 var_dump( rename($non_existent_dir_name, $new_dir_name) );
47 *** Testing rename() on non-existing file ***
54 *** Testing rename() on existing directory ***
[all …]
H A Drename_variation13.phpt2 Test rename() function : variation - various invalid paths
14 echo "*** Testing rename() with obscure files ***\n";
39 var_dump(rename($aFile, $name));
46 var_dump(rename($name, $aFile));
55 *** Testing rename() with obscure files ***
68 Warning: rename(%s/renameVar13/afile.tmp,): %s in %s on line %d
71 Warning: rename(,%s/renameVar13/afile.tmp): %s in %s on line %d
75 Warning: rename(%s/renameVar13/afile.tmp,): %s in %s on line %d
78 Warning: rename(,%s/renameVar13/afile.tmp): %s in %s on line %d
94 Warning: rename(%s/renameVar13/afile.tmp,php/php): %s directory in %s on line %d
[all …]
H A Drename_variation5.phpt2 Test rename() function: usage variations-6
12 /* test rename() by trying to rename an existing file/dir/link to the same name
27 var_dump( rename($linkname, $linkname) );
30 var_dump( rename($filename, $filename) );
33 var_dump( rename($dirname, $dirname) );
36 var_dump( rename($linkname, $dirname) );
38 var_dump( rename($linkname, $filename) );
41 var_dump( rename($filename, $dirname) );
43 var_dump( rename($filename, $linkname) );
48 var_dump( rename($dirname, $filename) );
[all …]
H A Drename_variation.phpt2 Test rename() function: usage variations-1 (Bug#42638)
16 /* rename files across directories */
17 echo "*** Testing rename() : rename files across directories ***\n";
29 /* loop through each $file and rename it to rename_variation_renamed.tmp */
35 var_dump( rename($src_filename, $dest_filename) );
51 *** Testing rename() : rename files across directories ***
58 Warning: rename(%s,%s): Not a directory in %s on line %d
H A Drename_variation-win32.phpt2 Test rename() function: usage variations
17 /* rename files across directories */
18 echo "*** Testing rename() : rename files across directories ***\n";
32 /* loop through each $file and rename it to rename_variation2.tmp */
38 var_dump( rename($src_filename, $dest_filename) );
57 *** Testing rename() : rename files across directories ***
64 Warning: rename(%s/rename_variation-win32/rename_variation.tmp/,%s/rename_variation2.tmp): The file…
H A Drename_variation2.phpt2 Test rename() function: usage variations-3
18 /* Testing rename() on soft and hard links with different permissions */
19 echo "\n*** Testing rename() on soft links ***\n";
29 //rename the link to a new name in the same dir
31 var_dump( rename( $linkname, $dest_linkname) );
37 // rename a link across dir
38 var_dump( rename($dest_linkname, $dest_dir."/rename_variation2_soft_link2.tmp"));
56 *** Testing rename() on soft links ***
H A Drename_variation3.phpt2 Test rename() function: usage variations-4
18 echo "\n*** Testing rename() on hard links ***\n";
26 //rename the link to a new name in the same dir
28 var_dump( rename( $filename, $dest_linkname) );
33 // rename a hard link across dir
34 var_dump( rename($dest_linkname, $dest_dir."/rename_variation3_hard_link2.tmp") );
51 *** Testing rename() on hard links ***
H A Drename_variation4.phpt2 Test rename() function: usage variations-5
17 echo "\n*** Testing rename() by renaming a file, link and directory to numeric name ***\n";
21 var_dump( rename($file_path."/rename_variation4.tmp", $file_path."/12345") );
22 // ensure that rename worked fine
31 var_dump( rename($file_path."/rename_variation4_dir/", $file_path."/12345") );
32 // ensure that rename worked fine
44 *** Testing rename() by renaming a file, link and directory to numeric name ***
H A Drename_variation2-win32.phpt2 Test rename() function: usage variations
17 echo "\n*** Testing rename() by renaming a file and directory to numeric name ***\n";
22 var_dump( rename($file_path."/rename_variation2-win32.tmp", $file_path."/12346") );
24 // ensure that rename worked fine
31 var_dump( rename($file_path."/rename_variation2-win32_dir/", $file_path."/12346") );
33 // ensure that rename worked fine
45 *** Testing rename() by renaming a file and directory to numeric name ***
H A Drename_variation13-win32.phpt2 Test rename() function : variation - various invalid paths
34 echo "*** Testing rename() with obscure files ***\n";
47 var_dump(rename($aFile, $name));
55 var_dump(rename($name, $aFile));
64 *** Testing rename() with obscure files ***
68 Warning: rename(-1,%safile.tmp): The system cannot find the file specified (code: 2) in %srename_va…
73 Warning: rename(1,%safile.tmp): The system cannot find the file specified (code: 2) in %srename_var…
91 Warning: rename(%s): The filename, directory name, or volume label syntax is incorrect (code: 123) …
94 Warning: rename(%s): The filename, directory name, or volume label syntax is incorrect (code: 123) …
105 Warning: rename(%safile.tmp,php/php): The system cannot find the path specified (code: 3) in %srena…
[all …]
H A Drename_variation1.phpt2 Test rename() function: usage variations-2
15 // rename dirs across directories
16 echo "\n*** Testing rename() : renaming directory across directories ***\n";
33 /* loop through each $src_dirs and rename it to $dest_dir */
39 // rename the src dir to a new dir in dest dir
40 var_dump( rename($src_dir, $dest_dir."/new_dir") );
58 *** Testing rename() : renaming directory across directories ***
H A Drename_variation1-win32.phpt2 Test rename() function: usage variations
16 // rename dirs across directories
17 echo "\n*** Testing rename() : renaming directory across directories ***\n";
36 /* loop through each $src_dirs and rename it to $dest_dir */
42 // rename the src dir to a new dir in dest dir
43 var_dump( rename($src_dir, $dest_dir."/new_dir") );
61 *** Testing rename() : renaming directory across directories ***
H A Drename_variation3-win32.phpt2 Test rename() function: usage variations
18 /* test rename() by trying to rename an existing file/dir to the same name
29 var_dump( rename($filename, $filename) );
33 var_dump( rename($dirname, $dirname) );
37 var_dump( rename($filename, $dirname) );
45 var_dump( rename($dirname, $filename) );
67 Warning: rename(%s/rename_variation3.tmp,%s/rename_variation3_dir): Access is denied (code: 5) in %…
H A Drename_variation9.phpt2 Test rename() function: basic functionality
5 echo "\n*** Testing rename() by giving stream context as third argument ***\n";
16 var_dump( rename($dir_name, $new_dir_name, $context) );
29 var_dump( rename($src_name, $dest_name, $context) );
41 *** Testing rename() by giving stream context as third argument ***
H A Drename_variation12.phpt2 Test rename() function : variation - various relative, absolute paths
13 echo "*** Testing rename() with absolute and relative paths ***\n";
50 $res = rename($dir."/".$fromFile, $dir."/".$toFile);
53 $res = rename($dir."/".$toFile, $dir."/".$fromFile);
66 *** Testing rename() with absolute and relative paths ***
86 Warning: rename(%s/renameVar12/renameVar12Sub/..///renameVar12Sub//..//../renameVar12Sub/renameMe.t…
91 Warning: rename(%s/renameVar12/renameVar12Sub/BADDIR/renameMe.tmp,%s/renameVar12/renameVar12Sub/BAD…
112 Warning: rename(BADDIR/renameMe.tmp,BADDIR/IwasRenamed.tmp): %s in %s on line %d
H A Drename_variation11-win32.phpt2 Test rename() function : variation - various relative, absolute paths
12 echo "*** Testing rename() with absolute and relative paths ***\n";
53 $res = rename($dir."\\".$fromFile, $dir."\\".$toFile);
56 $res = rename($dir."\\".$toFile, $dir."\\".$fromFile);
69 *** Testing rename() with absolute and relative paths ***
89 Warning: rename(%s\renameVar11\renameVar11Sub\..\\\renameVar11Sub\\..\\..\renameVar11Sub\renameMe.t…
94 Warning: rename(%s\renameVar11\renameVar11Sub\BADDIR\renameMe.tmp,%s\renameVar11\renameVar11Sub\BAD…
115 Warning: rename(BADDIR\renameMe.tmp,BADDIR\IwasRenamed.tmp): The system cannot find the path specif…
H A Drename_variation12-win32.phpt2 Test rename() function : variation - various relative, absolute paths
13 echo "*** Testing rename() with absolute and relative paths ***\n";
50 $res = rename($dir."/".$fromFile, $dir."/".$toFile);
53 $res = rename($dir."/".$toFile, $dir."/".$fromFile);
66 *** Testing rename() with absolute and relative paths ***
86 Warning: rename(%s/renameVar12/renameVar12Sub/..///renameVar12Sub//..//../renameVar12Sub/renameMe.t…
91 Warning: rename(%s/renameVar12/renameVar12Sub/BADDIR/renameMe.tmp,%s/renameVar12/renameVar12Sub/BAD…
112 Warning: rename(BADDIR/renameMe.tmp,BADDIR/IwasRenamed.tmp): The system cannot find the path specif…
H A Drename_basic.phpt2 Test rename() function: basic functionality
5 echo "*** Testing rename() on non-existing file ***\n";
17 var_dump( rename($src_name, $dest_name) ); // expecting true
35 *** Testing rename() on non-existing file ***
/php-src/ext/phar/tests/
H A Dbug47085.phpt2 Phar: PHP bug #47085: "rename() returns true even if the file in PHAR does not exist"
15 rename("phar://a.phar/x", "phar://a.phar/y");
16 var_dump(rename("phar://a.phar/x", "phar://a.phar/y"));
21 Warning: rename(): phar error: cannot rename "phar://a.phar/x" to "phar://a.phar/y" from extracted …
H A Dfopen_edgecases.phpt2 Phar: fopen/stat/fseek/unlink/rename edge cases
54 rename('phar://', 'phar://');
55 rename($pname . '/hi', 'phar://');
56 rename('phar://foo.phar/hi', 'phar://');
57 rename($pname . '/hi', 'phar://foo.phar/hi');
60 rename($pname . '/hi', $pname . '/there');
111 Warning: rename(): phar error: cannot rename "phar://" to "phar://": invalid or non-writable url "p…
113 Warning: rename(): phar error: cannot rename "phar://%sfopen_edgecases.phar.php/hi" to "phar://": i…
115 Warning: rename(): phar error: cannot rename "phar://foo.phar/hi" to "phar://": invalid or non-writ…
117 Warning: rename(): phar error: cannot rename "phar://%sfopen_edgecases.phar.php/hi" to "phar://foo.…
[all …]
/php-src/ext/dom/tests/modern/extensions/
H A Dnode_renaming.phpt17 echo "--- rename to $namespaceURIPretty $qualifiedNamePretty ---\n";
18 $target->rename($namespaceURI, $qualifiedName);
42 --- rename to "urn:x" "x:foo" ---
49 --- rename to "urn:x" "a:foo" ---
56 --- rename to "" "foo" ---
63 --- rename to null "bar" ---
71 --- rename to "urn:x" "x:foo" ---
78 --- rename to "urn:x" "a:foo" ---
85 --- rename to "" "foo" ---
92 --- rename to null "bar" ---
H A Dattribute_renaming_conflict.phpt21 $root->attributes[0]->rename(NULL, 'c');
26 $root->attributes[0]->rename(NULL, 'c');
31 $root->attributes[1]->rename(NULL, 'a');
36 $root->attributes[1]->rename('urn:a', 'foo');
41 $root->attributes[3]->rename('', 'a');
46 $root->firstElementChild->attributes[0]->rename(NULL, 'hello');
51 $root->firstElementChild->attributes[1]->rename(NULL, 'my-attr');
/php-src/ext/sqlite3/tests/
H A Dsqlite3_rename_column.phpt2 SQLite3 - rename column while SQLite3Result is open
8 die("skip: sqlite3 library version < 3.25: no support for rename column");
25 $db->exec('alter table tbl rename column orig to changed');

Completed in 24 milliseconds

123