Fix RT#49267
[catagits/Catalyst-Runtime.git] / lib / Catalyst / Script / Test.pm
CommitLineData
0ba6e8aa 1package Catalyst::Script::Test;
accb0640 2use Moose;
95389116 3use Catalyst::Test ();
d9a32f71 4use namespace::autoclean;
451b2a44 5
d3082fac 6with 'Catalyst::ScriptRole';
451b2a44 7
8sub run {
9 my $self = shift;
10
e25affcb 11 Catalyst::Test->import($self->application_name);
57dc50b0 12
3453b929 13 print request($self->ARGV->[0])->content . "\n";
451b2a44 14}
15
73e4f0f1 16
d6e8e664 17__PACKAGE__->meta->make_immutable;
d3082fac 18
19=head1 NAME
20
21Catalyst::Script::Test - Test Catalyst application on the command line
22
23=head1 SYNOPSIS
24
3dcfb4c8 25 myapp_test.pl [options] /path
26
27 Options:
28 -h --help display this help and exits
d3082fac 29
30=head1 DESCRIPTION
31
3dcfb4c8 32Script to perform a test hit against your application and display the output.
d3082fac 33
34=head1 AUTHORS
35
36Catalyst Contributors, see Catalyst.pm
37
38=head1 COPYRIGHT
39
40This library is free software. You can redistribute it and/or modify it under
41the same terms as Perl itself.
42
43=cut