File Coverage

blib/lib/HTTP/Engine/Role/ResponseWriter/Finalize.pm
Criterion Covered Total %
statement 10 10 100.0
branch 2 2 100.0
condition n/a
subroutine 3 3 100.0
pod 0 1 0.0
total 15 16 93.7


line stmt bran cond sub pod time code
1             package HTTP::Engine::Role::ResponseWriter::Finalize;
2 29     29   30425 use Any::Moose '::Role';
  29         129  
  29         188  
3 29     29   12151 use Carp ();
  29         59  
  29         3249  
4              
5             requires qw(write output_header output_body);
6              
7             sub finalize {
8 43     43 0 111 my($self, $req, $res) = @_;
9 43 100       330 Carp::croak "argument missing" unless $res;
10              
11 42         224 $self->output_header($req, $res);
12 42         343 $self->output_body($res->body);
13             }
14              
15             1;