blob: d149098df07ebd689ccba6c798e4dae8dc8f78dd (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
--TEST--
mkdir(dir, 0777) tests
--SKIPIF--
<?php
if (substr(PHP_OS, 0, 3) == 'WIN') {
die('skip no symlinks on Windows');
}
?>
--FILE--
<?php
var_dump(mkdir("mkdir-002", 0777));
var_dump(mkdir("mkdir-002/subdir", 0777));
var_dump(`ls -l mkdir-002`);
var_dump(rmdir("mkdir-002/subdir"));
var_dump(rmdir("mkdir-002"));
var_dump(mkdir("./mkdir-002", 0777));
var_dump(mkdir("./mkdir-002/subdir", 0777));
var_dump(`ls -l ./mkdir-002`);
var_dump(rmdir("./mkdir-002/subdir"));
var_dump(rmdir("./mkdir-002"));
var_dump(mkdir(dirname(__FILE__)."/mkdir-002", 0777));
var_dump(mkdir(dirname(__FILE__)."/mkdir-002/subdir", 0777));
$dirname = dirname(__FILE__)."/mkdir-002";
var_dump(`ls -l $dirname`);
var_dump(rmdir(dirname(__FILE__)."/mkdir-002/subdir"));
var_dump(rmdir(dirname(__FILE__)."/mkdir-002"));
echo "Done\n";
?>
--EXPECTF--
bool(true)
bool(true)
string(%d) "%s
d%s subdir
"
bool(true)
bool(true)
bool(true)
bool(true)
string(%d) "%s
d%s subdir
"
bool(true)
bool(true)
bool(true)
bool(true)
string(%d) "%s
d%s subdir
"
bool(true)
bool(true)
Done
|