Subject: | Test #54 failed due to locale settings |
Hi,
t/date.t has following test:
Show quoted text
> # Don't assume much about how this locale spells 'Jan'.54
> ok( $d->format('%d %b %Y') =~ m/17 \D+ 1972/ );
But on some locales (at least Japanese locales on WindowsXP/FreeBSD),
the return value of strftime('%b') contains the digits. As a result,
this test fails.
I have tested on the following environments with Date-Simple-3.03:
* Windows XP Professional SP3 (Japanese) with strawberry-perl-5.10.1.0
* FreeBSD 7.1-RELEASE-p8 with perl 5.10.0 (i386-freebsd-64int)
You can reproduce this problem by the following steps:
* On Windows XP, open "Regional and Language Options" from Control Panel,
select "Japanese" at "Standards and formats".
* On FreeBSD or some UNIX-like OSes, set LC_TIME to Japanese locales
(ja_JP.eucJP, etc).
You may get the following results after this setting:
Show quoted text> # perl -MPOSIX -e "print POSIX::strftime('%d %b %Y', localtime)"
> 11 11 2009
Thanks,
Masahiro Konishi