[Catalyst] [ANNOUNCE] Catalyst-Runtime 5.80015

Nilson Santos Figueiredo Jr. acid06 at gmail.com
Mon Dec 7 03:36:08 GMT 2009


On Sun, Dec 6, 2009 at 6:15 PM, kmx <kmx at volny.cz> wrote:
> 2) on clean Win32/strawberry perl 5.8.9 and 5.10.1 the Catalyst::Runtime
> r12225 pass all tests

Just tried installing it on Windows XP, AS Perl 5.8.9 build 825 and I
can confirm it fails:

t/aggregate/utf8_content_length.t ..................................... 1/?
#   Failed test '/binary correct content length'
#   at t/aggregate/utf8_content_length.t line 21.
#          got: '5700'
#     expected: '5701'

#   Failed test '/binary_utf8 correct content length'
#   at t/aggregate/utf8_content_length.t line 26.
#          got: '5700'
#     expected: '5701'
# Looks like you failed 2 tests of 6.
t/aggregate/utf8_content_length.t ..................................... Dubious,
 test returned 2 (wstat 512, 0x200)

The fix is very simple, though. Just add a:

  binmode($fh);

In TestAppEncoding::Controller::Root.

On Win32, whenever you're dealing with files containing binary content
you need to tell PerlIO to get rid of the :crlf conversion layer -
this is the simplest (and most backwards compatible way) of doing it.

After this change, all tests pass. The change is fairly simple so I
guess anyone can do it without a proper patch.

-Nilson Santos F. Jr.



More information about the Catalyst mailing list