Branch Coverage

blib/lib/HTTP/Body/MultiPart.pm
Criterion Covered Total %
branch 35 42 83.3


line true false branch
34 0 18 unless ($self->content_type =~ /boundary=\"?([^\";]+)\"?/)
54 482 0 if ($$self{'state'} =~ /^(preamble|boundary|header|body)$/) { }
56 35 447 unless $self->$method
124 0 18 unless ($index >= 0)
143 143 19 if (index($$self{'buffer'}, $self->delimiter_begin . $self->crlf) == 0)
152 16 3 if (index($$self{'buffer'}, $self->delimiter_end . $self->crlf) == 0)
174 7 143 unless ($index >= 0)
184 0 209 if (s/^[ \t]+//) { }
200 0 209 if (exists $$self{'part'}{'headers'}{$field}) { }
202 0 0 unless ref $_ eq 'ARRAY'
225 9 143 if ($index < 0)
230 4 5 unless ($length > 0)
264 140 8 unless (exists $$part{'name'})
273 65 75 if (defined $filename)
276 51 14 if ($filename ne '')
278 49 2 $basename =~ /$basename_regexp/ ? :
288 51 97 if ($$part{'fh'} and my $length = length $$part{'data'})
292 143 5 if ($$part{'done'})
294 67 76 if (exists $$part{'filename'}) { }
295 53 14 if ($$part{'filename'} ne '')
296 51 2 if defined $$part{'fh'}