X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2Flive%2Flib%2FTestApp.pm;h=594dfa3a4c0b4a2526db7beaf088f3ad693fa2ed;hb=684d10edf63074f94667d437db01d30b8d13cefc;hp=95d77e22d9b9e6c0a47cba00ae398492eecec26e;hpb=e0e47c71fdefb2f22ce618560c6546bade22ea53;p=catagits%2FCatalyst-Runtime.git diff --git a/t/live/lib/TestApp.pm b/t/live/lib/TestApp.pm index 95d77e2..594dfa3 100644 --- a/t/live/lib/TestApp.pm +++ b/t/live/lib/TestApp.pm @@ -12,7 +12,7 @@ TestApp->setup; sub index : Private { my ( $self, $c ) = @_; - $c->res->body( 'root index' ); + $c->res->body('root index'); } sub global_action : Private { @@ -33,8 +33,11 @@ sub execute { elsif ( $action =~ /\/(\w+)$/ ) { $method = $1; } + elsif ( $action =~ /^(\w+)$/ ) { + $method = $action; + } - if ( $class && $method ) { + if ( $class && $method && $method !~ /^_/ ) { my $executed = sprintf( "%s->%s", $class, $method ); my @executed = $c->response->headers->header('X-Catalyst-Executed'); push @executed, $executed; @@ -47,4 +50,8 @@ sub execute { return $c->SUPER::execute(@_); } +{ + no warnings 'redefine'; + sub Catalyst::Log::error { } +} 1;