1--TEST--
2Test mkdir/rmdir big5 to UTF-8 path
3--SKIPIF--
4<?php
5include dirname(__FILE__) . DIRECTORY_SEPARATOR . "util.inc";
6
7skip_if_not_win();
8if (getenv("SKIP_SLOW_TESTS")) die("skip slow test");
9skip_if_no_required_exts();
10
11?>
12--FILE--
13<?php
14/*
15#vim: set fileencoding=big5
16#vim: set encoding=big5
17*/
18
19include dirname(__FILE__) . DIRECTORY_SEPARATOR . "util.inc";
20
21$item = iconv('big5', 'utf-8', "���զh�r�`���|"); // BIG5 string
22$prefix = create_data("dir_big5", $item . "5");
23$path = $prefix . DIRECTORY_SEPARATOR . "${item}5";
24
25$subpath = $path . DIRECTORY_SEPARATOR . "${item}4";
26
27/* The mb dirname exists*/
28var_dump(file_exists($path));
29
30var_dump(mkdir($subpath));
31var_dump(file_exists($subpath));
32
33get_basename_with_cp($subpath, 65001);
34
35var_dump(rmdir($subpath));
36remove_data("dir_big5");
37
38?>
39===DONE===
40--EXPECTF--
41bool(true)
42bool(true)
43bool(true)
44Active code page: 65001
45getting basename of %s\測試多字節路徑5\測試多字節路徑4
46string(22) "測試多字節路徑4"
47bool(true)
48string(%d) "%s\測試多字節路徑5\測試多字節路徑4"
49Active code page: %d
50bool(true)
51===DONE===
52