CatalystX-Eta
view release on metacpan or search on metacpan
t/lib/MyApp/Test/Further.pm view on Meta::CPAN
decode_response => sub {
my $res = shift;
return decode_json( $res->content );
}
);
for (qw/rest_get rest_put rest_head rest_delete rest_post rest_reload rest_reload_list/) {
eval( 'sub ' . $_ . ' { return $obj->' . $_ . '(@_) }' );
}
sub stash_test($&) {
$obj->stash_ctx(@_);
}
sub stash($) {
$obj->stash->{ $_[0] };
}
sub test_instance { $obj }
sub db_transaction (&) {
my ( $subref, $modelname ) = @_;
my $schema = MyApp->model( $modelname || 'DB' );
( run in 0.750 second using v1.01-cache-2.11-cpan-65fba6d93b7 )