CPAN
Test::WWW::Mechanize
http://search.cpan.org/~petdance/Test-WWW-Mechanize-1.12/Mechanize.pm
Catalyst::Manual::Cookbook
http://search.cpan.org/~sri/Catalyst-5.55/lib/Catalyst/Manual/Cookbook.pod
http://www.tcool.org/catalyst/Cookbook.html
Catalyst::View::TT
Hoge.pm
__PACKAGE__->config(
name => 'Hoge',
root => Hoge->path_to('root'),
'View::TT' => {
INCLUDE_PATH => [
Hoge->path_to( 'root'),
],TEMPLATE_EXTENSION => '.tt',
CATALYST_VAR => 'Catalyst',
TIMER => 1,
},
);
Hoge/Controller/Root.pm
sub hoge : Global {
my ( $self, $c ) = @_;
$c->stash->{message} = "hoge";
}
root/hoge.tt
[% message %]
こんな感じ