projects
/
m6w6
/
ext-http
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
|
github
raw
|
inline
| side by side
fix tests for libcurl >= 7.48
[m6w6/ext-http]
/
tests
/
urlparser010.phpt
diff --git
a/tests/urlparser010.phpt
b/tests/urlparser010.phpt
index a82b7a86df7a42258e9620655f6bc0f6bb41cb65..ae63ae7b4050e4eba43b60049a565d9736e0342e 100644
(file)
--- a/
tests/urlparser010.phpt
+++ b/
tests/urlparser010.phpt
@@
-1,19
+1,24
@@
--TEST--
--TEST--
-url parser multibyte/
utf-8
/topct
+url parser multibyte/
locale
/topct
--SKIPIF--
<?php
include "skipif.inc";
--SKIPIF--
<?php
include "skipif.inc";
+if (!defined("http\\Url::PARSE_MBLOC") or
+ !stristr(setlocale(LC_CTYPE, NULL), ".utf")) {
+ die("skip need http\\Url::PARSE_MBLOC support and LC_CTYPE=*.UTF-8");
+}
+
?>
--FILE--
<?php
echo "Test\n";
$urls = array(
?>
--FILE--
<?php
echo "Test\n";
$urls = array(
- "http://mike:paßwort@
sörver.ne
t/for/€/?by=¢#ø"
+ "http://mike:paßwort@
𐌀𐌁𐌂.i
t/for/€/?by=¢#ø"
);
foreach ($urls as $url) {
);
foreach ($urls as $url) {
- var_dump(
http\Url::parse($url, http\Url::PARSE_MBUTF8
|http\Url::PARSE_TOPCT));
+ var_dump(
new http\Url($url, null, http\Url::PARSE_MBLOC
|http\Url::PARSE_TOPCT));
}
?>
DONE
}
?>
DONE
@@
-27,7
+32,7
@@
object(http\Url)#%d (8) {
["pass"]=>
string(12) "pa%C3%9Fwort"
["host"]=>
["pass"]=>
string(12) "pa%C3%9Fwort"
["host"]=>
- string(1
1) "sörver.ne
t"
+ string(1
5) "𐌀𐌁𐌂.i
t"
["port"]=>
NULL
["path"]=>
["port"]=>
NULL
["path"]=>