Commit | Line | Data |
b3986722 |
1 | package ACLTestApp; |
2 | use Test::More; |
3 | |
4 | use strict; |
5 | use warnings; |
6 | use MRO::Compat; |
7 | use Scalar::Util (); |
4fb27043 |
8 | use TestLogger; |
b3986722 |
9 | |
10 | use base qw/Catalyst Catalyst::Controller/; |
11 | use Catalyst qw//; |
12 | |
4fb27043 |
13 | __PACKAGE__->log(TestLogger->new); |
14 | |
b3986722 |
15 | sub execute { |
16 | my $c = shift; |
17 | my ( $class, $action ) = @_; |
18 | |
19 | if ( Scalar::Util::blessed($action) |
20 | and $action->name ne "foobar" ) { |
21 | eval { $c->detach( 'foobar', [$action, 'foo'] ) }; |
22 | } |
23 | |
24 | $c->next::method( @_ ); |
25 | } |
26 | |
27 | __PACKAGE__->setup; |
28 | |
29 | 1; |