Branch Coverage

blib/lib/HTTP/Body/MultiPart.pm
Criterion Covered Total %
branch 36 44 81.8


line true false branch
34 0 23 unless ($self->content_type =~ /boundary=\"?([^\";]+)\"?/)
54 607 0 if ($self->{'state'} =~ /^(preamble|boundary|header|body)$/) { }
56 44 563 unless $self->$method
124 0 23 unless ($index >= 0)
143 180 24 if (index($self->{'buffer'}, $self->delimiter_begin . $self->crlf) == 0)
152 21 3 if (index($self->{'buffer'}, $self->delimiter_end . $self->crlf) == 0)
174 7 180 unless ($index >= 0)
184 0 270 if (s/^[ \t]+//) { }
200 0 270 if (exists $self->{'part'}{'headers'}{$field}) { }
202 0 0 unless ref $_ eq "ARRAY"
225 13 180 if ($index < 0)
230 7 6 unless ($length > 0)
266 177 9 unless (exists $part->{'name'})
275 88 89 if (defined $filename)
278 72 16 if ($filename ne "")
280 69 3 $basename =~ /$basename_regexp/ ? :
282 0 72 $file_temp_template ? :
294 71 115 if ($part->{'fh'} and my $length = length $part->{'data'})
298 180 6 if ($part->{'done'})
300 90 90 if (exists $part->{'filename'}) { }
301 74 16 if ($part->{'filename'} ne "")
302 72 2 if defined $part->{'fh'}