Branch Coverage

blib/lib/STF/Dispatcher/PSGI.pm
Criterion Covered Total %
branch 62 84 73.8


line true false branch
28 0 2 unless my $impl = $args{'impl'}
31 0 20 unless $impl->can($method)
42 2 0 if ($self->nosniff_header)
59 20 40 if ($method =~ /^(?:GET|HEAD)$/) { }
18 22 elsif ($method eq 'PUT') { }
10 12 elsif ($method eq 'DELETE') { }
2 10 elsif ($method eq 'POST') { }
10 0 elsif ($method eq 'MOVE') { }
63 8 10 if ($cl == 0) { }
83 0 70 unless ($path =~ m[^/([^/]+)(?:/(.+)$)?])
93 2 6 if ($object_name)
101 2 4 if ($bucket)
109 0 4 unless ($bucket)
126 2 8 unless ($bucket)
130 2 6 unless ($object_name)
140 0 6 if ($code = $input->can('rewind')) { }
6 0 elsif ($code = $input->can('seek')) { }
147 6 0 if ($req->content_type)
164 0 6 unless ($object)
179 4 6 unless ($bucket)
180 2 2 if (not $object_name) { }
189 2 4 unless ($object_name)
195 0 2 unless ($ret)
207 2 2 unless ($is_valid)
211 2 0 if ($self->impl->delete_object({'bucket', $bucket, 'object_name', $object_name, 'request', $req})) { }
230 2 18 unless ($bucket)
240 6 10 unless ($object)
245 10 0 if (my $ct = $object->can('content_type'))
248 10 0 if (my $lm = $object->can('modified_on'))
252 2 8 $req->method eq 'HEAD' ? :
266 0 2 unless ($bucket)
275 0 2 unless ($is_valid)
288 2 0 if ($ret) { }
304 0 10 unless ($bucket)
309 4 6 unless ($object_name)
311 0 4 unless ($dest_bucket)
314 0 4 if ($dest_object)
322 2 2 if ($ok) { }
334 0 6 unless ($is_valid)
342 2 4 if ($dest_bucket_name eq $bucket_name) { }
349 2 2 unless ($dest_bucket)
362 0 4 unless ($rv)