Branch Coverage

blib/lib/Protocol/HTTP2/Connection.pm
Criterion Covered Total %
branch 61 104 58.6


line true false branch
29 18 19 $type == 1 ? :
95 16 132 if exists $opts{$_}
98 15 22 if (exists $opts{'settings'})
143 1 1 if ($self->frame_header_decode(\$$self{'queue'}[$_], 0))[1] != 9
156 7 0 unless $self->shutdown
164 8 14 if @_
170 12 34 if @_
176 28 173 if @_
182 0 248 if @_
190 0 104 if $stream_id == 0 or $type == 4 or $type == 7 or $self->upgrade or not $self->preface
201 0 0 if not defined $prev_state and $type == 3 and $act eq 'send'
225 1 103 if (my $ps = $self->stream_pending_state($stream_id)) { }
28 75 elsif ($prev_state == 1) { }
1 74 elsif ($prev_state == 3) { }
0 74 elsif ($prev_state == 2) { }
69 5 elsif ($prev_state == 4) { }
5 0 elsif ($prev_state == 5) { }
226 0 1 if ($type != 9) { }
1 0 elsif ($flags & 4) { }
234 0 1 if $promised_sid
243 27 1 if ($type == 1 and $cln2srv) { }
0 1 elsif ($type == 5 and $srv2cln) { }
0 1 elsif ($type == 3 and $act eq 'send') { }
0 1 elsif ($type != 2) { }
244 25 2 $flags & 1 ? :
249 0 0 if $flags & 4
270 0 1 if ($flags & 1 and $type == 0 || $type == 1) { }
0 1 elsif ($type == 3) { }
282 0 0 if ($type == 3) { }
0 0 elsif ($type == 1 and $srv2cln) { }
0 0 elsif ($type != 2 and $cln2srv) { }
286 0 0 $flags & 1 ? :
297 22 47 if ($type == 3 or $flags & 1 and $srv2cln) { }
0 47 elsif (not grep({$type == $_;} 8, 2) and $cln2srv) { }
313 0 5 if ($type != 2 and ($type != 8 and $cln2srv))
332 14 10 $end ? :
333 24 0 if length $header_block <= $max_size
338 0 0 length $header_block <= $max_size ? :
350 0 0 length $header_block <= $max_size ? :
356 0 0 length $header_block <= $max_size ? :
365 15 5 defined $chunk ? :
366 5 15 if defined $end
373 20 40 if $size > $_
377 0 20 if ($l != 0 and $size == 0)
384 5 15 $end && $l == $size ? :
388 20 0 if $l == $size
401 0 0 if (@_ and not $$self{'shutdown'})
403 0 0 if exists $$self{'on_error'}
417 0 308 unless exists $$s{$setting}
418 13 295 if @_ > 3
440 42 20 if (@_)
471 0 0 if $self->stream_state($stream_id) == 5