Condition Coverage

blib/lib/PAGI/WebSocket.pm
Criterion Covered Total %
condition 57 68 83.8


and 3 conditions

line !l l&&!r l&&r condition
16 1 1 103 $scope and ref $scope eq "HASH"
18 1 1 101 $receive and ref $receive eq "CODE"
20 1 1 99 $send and ref $send eq "CODE"
241 2 0 11 builtin::blessed($r) and $r->isa("Future")
584 4 0 1 builtin::blessed($r) and $r->isa("Future")

or 2 conditions

line l !l condition
23 99 0 $scope->{'type'} // ""
53 14 1 +(shift())->{'scope'}{'query_string'} // ""
54 1 1 +(shift())->{'scope'}{'scheme'} // "ws"
55 1 1 +(shift())->{'scope'}{'http_version'} // "1.1"
56 1 1 +(shift())->{'scope'}{'subprotocols'} // []
64 9 3 $self->{'scope'}{'pagi.stash'} //= {}
70 5 2 $self->{'scope'}{'state'} // {}
77 1 1 $self->{'scope'}{'path_params'} // {}
82 4 1 $self->{'scope'}{'path_params'} // {}
108 1 25 delete $opts{'strict'} // 0
109 4 22 delete $opts{'raw'} // 0
121 23 0 $key //= ""
122 22 1 $val //= ""
162 4 0 $self->{'scope'}{'headers'} // []
176 1 0 $self->{'scope'}{'headers'} // []
215 36 1 $code // 1005
216 36 1 $reason // ""
323 2 10 $code //= 1000
324 2 10 $reason //= ""
471 16 4 $event->{'code'} // 1005
472 7 13 $event->{'reason'} // ""
602 5 0 $interval //= 0

or 3 conditions

line l !l&&r !l&&!r condition
52 1 0 1 $s->{'scope'}{'raw_path'} // $s->{'scope'}{'path'}
469 0 20 54 not defined $event or $event->{'type'} eq "websocket.disconnect"
578 5 0 0 $event->{'text'} // $event->{'bytes'}