8 use Catalyst::Test qw/TestAppEncoding/;
10 if ( $ENV{CATALYST_SERVER} ) {
11 plan skip_all => 'This test does not run live';
15 my $fn = "$Bin/../catalyst_130pix.gif";
16 ok -r $fn, 'Can read catalyst_130pix.gif';
19 my $r = request('/binary');
20 is $r->code, 200, '/binary OK';
21 is $r->header('Content-Length'), $size, '/binary correct content length';
24 # Test that even if what is really binary has been upgraded into character
25 # octets in perl, then when we output it we get the correct content length.
26 # The issue was initially described in the thread 'Avoiding UTF8 in
27 # Catalyst': http://lists.scsys.co.uk/pipermail/catalyst/2009-November/023912.html.
28 # FIXME! (See ml thread re 5.80015 release)
29 skip 'Known not to work on Win32', 2 if ($^O eq 'MSWin32');
30 my $r = request('/binary_utf8');
31 is $r->code, 200, '/binary_utf8 OK';
32 is $r->header('Content-Length'), $size, '/binary_utf8 correct content length';