From: Tomas Doran Date: Thu, 18 Dec 2008 00:53:44 +0000 (+0000) Subject: Test for basename fixes X-Git-Tag: 5.8000_05~88 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Runtime.git;a=commitdiff_plain;h=a12e6f1755826fd4f52bfaace47aef562cb758b8 Test for basename fixes --- diff --git a/Changes b/Changes index 1882335..f92595c 100644 --- a/Changes +++ b/Changes @@ -1,5 +1,8 @@ # This file documents the revision history for Perl extension Catalyst. + - Fix bug causing Catalyst::Request::Upload's basename method + to return undef (t0m) + - Test for this (Carl Franks) - Fix loading of classes which do not define any symbols to not die, as it didn't in 5.70 (t0m) - Test for this (t0m) @@ -20,7 +23,6 @@ Catalyst::Engine::CGI: _header_buf Catalyst::Engine::HTTP: options, _keepalive, _write_error Catalyst::Request: _path - Catalyst::Request::Upload: basename Catalyst::Stats: tree (t0m) - Fix issues in Catalyst::Controller::WrapCGI diff --git a/t/aggregate/live_engine_request_uploads.t b/t/aggregate/live_engine_request_uploads.t index 47913db..df98f08 100644 --- a/t/aggregate/live_engine_request_uploads.t +++ b/t/aggregate/live_engine_request_uploads.t @@ -6,7 +6,7 @@ use warnings; use FindBin; use lib "$FindBin::Bin/../lib"; -use Test::More tests => 101; +use Test::More tests => 105; use Catalyst::Test 'TestApp'; use Catalyst::Request; @@ -134,6 +134,7 @@ use Path::Class::Dir; is( $upload->type, $part->content_type, 'Upload Content-Type' ); is( $upload->filename, $parameters{filename}, 'Upload filename' ); is( $upload->size, length( $part->content ), 'Upload Content-Length' ); + is( $upload->basename, $parameters{filename}, 'Upload basename' ); SKIP: { @@ -276,6 +277,7 @@ use Path::Class::Dir; is( $upload->type, $part->content_type, 'Upload Content-Type' ); is( $upload->size, length( $part->content ), 'Upload Content-Length' ); is( $upload->filename, 'catalyst_130pix.gif', 'Upload Filename' ); + is( $upload->basename, 'catalyst_130pix.gif', 'Upload basename' ); SKIP: {