4 use Catalyst qw/Test::Errors Test::Headers Test::Plugin/;
9 TestApp->config( name => 'TestApp', root => '/some/dir' );
14 my ( $self, $c ) = @_;
15 $c->res->body('root index');
18 sub global_action : Private {
19 my ( $self, $c ) = @_;
20 $c->forward('TestApp::View::Dump::Request');
25 my $class = ref( $c->component( $_[0] ) ) || $_[0];
30 if ( $action =~ /->(\w+)$/ ) {
33 elsif ( $action =~ /\/(\w+)$/ ) {
36 elsif ( $action =~ /^(\w+)$/ ) {
40 if ( $class && $method && $method !~ /^_/ ) {
41 my $executed = sprintf( "%s->%s", $class, $method );
42 my @executed = $c->response->headers->header('X-Catalyst-Executed');
43 push @executed, $executed;
44 $c->response->headers->header(
45 'X-Catalyst-Executed' => join ', ',
50 return $c->SUPER::execute(@_);
54 no warnings 'redefine';
55 sub Catalyst::Log::error { }