Commit | Line | Data |
---|---|---|
e10b40fd | 1 | package TestAppController::Controller::Foo; |
2 | ||
3 | use Moose; | |
4 | use namespace::autoclean; | |
5 | BEGIN { extends 'Catalyst::Controller' }; | |
6 | ||
7 | has foo => ( | |
8 | isa => 'Str', | |
9 | is => 'ro', | |
10 | default => 'bar', | |
11 | ); | |
12 | ||
13 | sub test_controller :Local { | |
14 | my ( $self, $c ) = @_; | |
15 | ||
16 | $c->res->body( $c->controller->foo ); | |
17 | } | |
18 | ||
19 | __PACKAGE__->meta->make_immutable; | |
20 | ||
21 | 1; |