Subject: | Locale-dependent test failures |
The t/Bio-Gonzales-Util-Log.t and t/Bio-Gonzales-Util-Log_threads.t tests may fail under some circumstances:
* a locale which uses non-ascii characters is in effect
* the current month abbreviation contains non-ascii characters
This is currently the case in the German locale (e.g. using LC_ALL=de_DE.UTF-8) (March translates to "März" which abbreviates to "Mär").
The test output looks like this:
# Failed test 'log debug test'
# at t/Bio-Gonzales-Util-Log.t line 18.
Wide character in print at /usr/perl5.16.3t/lib/site_perl/5.16.3/Test/Builder.pm line 1826.
# '[21 M�r 20:04:08] [DEBUG]: testdebug
# '
# doesn't match '(?^:^\[\d+ \w+ \d\d:\d\d:\d\d\] \[DEBUG\]: testdebug$)'
# Looks like you failed 1 test of 2.
t/Bio-Gonzales-Util-Log.t ..................
Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/2 subtests
# Failed test 'log debug test'
# at t/Bio-Gonzales-Util-Log_threads.t line 27.
Wide character in print at /usr/perl5.16.3t/lib/site_perl/5.16.3/Test/Builder.pm line 1826.
# '[21 M�r 20:04:09] [DEBUG] (t0): testdebug
# '
# doesn't match '(?^:^\[\d+ \w+ \d\d:\d\d:\d\d\] \[DEBUG\] \(t0\): testdebug$)'
# Looks like you failed 1 test of 2.
t/Bio-Gonzales-Util-Log_threads.t ..........
Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/2 subtests
Possible workarounds:
* make sure that an English locale is used (i.e by setting LC_ALL=C or so)
* match the month name with \S+ instead of \w+