php-src/ext/date/tests/bug65184.phpt

29 lines
549 B
Plaintext
Raw Normal View History

--TEST--
Test bug #65184 strftime() returns insufficient-length string under multibyte locales
--SKIPIF--
<?php
if (strtoupper(substr(PHP_OS, 0, 3)) != 'WIN') {
die("skip Test is valid for Windows");
}
?>
--INI--
date.timezone = UTC
--FILE--
<?php
setlocale(LC_ALL, 'Japanese_Japan.932');
2013-07-03 20:52:51 +00:00
/* timestamp has to be some wednesday */
$s = strftime('%A', 1372884126);
for ($i = 0; $i < strlen($s); $i++) {
printf("%x ", ord($s[$i]));
}
echo "\n";
2013-07-03 20:52:51 +00:00
echo strlen(strftime('%A')), "\n";
?>
===DONE===
--EXPECT--
90 85 97 6a 93 fa
2013-07-03 20:52:51 +00:00
6
===DONE===