Branch Coverage

blib/lib/HTTP/StreamParser.pm
Criterion Covered Total %
branch 24 30 80.0


line true false branch
125 0 163 unless my $handler = $self->can($$self{'state'})
198 1 1 if ($$buf =~ s/^([A-Z]+)(?=\s)//)
200 0 1 unless $self->validate_method($$self{'method'})
224 1 2 if ($$buf =~ s/^(\d{3})(?=\s)//)
226 0 1 unless $self->validate_code($$self{'code'})
242 1 1 if ($$buf =~ s/^(.*?)(?=$CRLF)//)
259 1 1 if ($$buf =~ s[^(.*)(\s+http/\d+\.\d+$CRLF)][$2]i)
276 2 3 if ($$buf =~ s[^(HTTP)/(\d+.\d+)(?=\s)][]i)
300 2 11 if lc $k eq 'content-length'
301 2 11 if (exists $multi_valued{$k}) { }
309 2 132 if ($$buf =~ s/^$CRLF//)
328 4 0 if $$buf =~ s/^ //
343 2 0 if $$buf =~ s/^$CRLF//
360 5 0 if defined $$self{'remaining'}
363 2 7 if 0 == ($$self{'remaining'} // 1)