HTTP::Engine::Interface::Test - HTTP::Engine Test Interface
use Data::Dumper; use HTTP::Engine; use HTTP::Request; my $response = HTTP::Engine->new( interface => { module => 'Test', request_handler => sub { my $req = shift; HTTP::Engine::Response->new( body => Dumper($req) ); } }, )->run(HTTP::Request->new( GET => 'http://localhost/' ), env => \%ENV); print $response->content;
HTTP::Engine::Interface::Test is test engine base class
HTTP::Engine::Test::Request
Kazuhiro Osawa <ko@yappo.ne.jp>
To install HTTP::Engine, copy and paste the appropriate command in to your terminal.
cpanm
cpanm HTTP::Engine
CPAN shell
perl -MCPAN -e shell install HTTP::Engine
For more information on module installation, please visit the detailed CPAN module installation guide.