Branch Coverage

lib/RPC/Switch/Client/Tiny/SessionCache.pm
Criterion Covered Total %
branch 50 80 62.5


line true false branch
22 4 8 unless $self->{'session_expire'}
23 12 0 unless $self->{'session_idle'}
24 12 0 unless $self->{'session_persist_user'}
25 11 1 unless $self->{'max_user_session'}
40 7 32 if ($ret == 0)
43 16 23 if ($ret < 0) { }
49 7 16 if (defined $found)
59 7 0 if ($self->{'expiring'}[$idx]{'id'} eq $session->{'id'})
62 0 0 if --$idx < 0
74 7 16 if ($found) { }
79 7 0 if (defined $sessionidx)
96 0 0 if ($found)
98 0 0 if (defined $sessionidx)
132 14 10 exists $child->{'runtime'} ? :
134 0 24 unless exists $child->{'session'}
136 3 21 if (exists $self->{'active'}{$child->{'session'}{'id'}})
140 2 19 if ($diff < 0)
143 4 0 if ($self->{'max_user_session'} and exists $child->{'session'}{'user'})
145 3 1 if (exists $self->{'per_user'}{$user})
147 2 1 if ($cnt >= $self->{'max_user_session'})
153 8 9 if $self->{'trace_cb'}
162 20 8 defined $msg_id ? :
163 20 8 defined $msg_vci ? :
165 12 16 if (exists $self->{'active'}{$session_id})
169 0 0 if ($self->{'max_user_session'} and exists $child->{'session'}{'user'})
171 0 0 if (exists $self->{'per_user'}{$user})
173 0 0 if (scalar keys %{$$self{"per_user"}{$user};} == 0)
180 3 9 if $self->{'trace_cb'}
189 0 0 if ($self->{'max_user_session'})
200 0 5 unless exists $child->{'session'}
202 0 0 if ($self->{'max_user_session'} and exists $child->{'session'}{'user'})
205 0 0 if (exists $self->{'active'}{$session_id})
208 0 0 if ($idle >= $self->{'session_idle'})
221 0 3 unless defined $s
231 3 15 if (exists $set_session->{'expires'})
235 15 3 unless $expiretime
237 4 14 if exists $set_session->{'user'}
254 2 0 unless (list_empty($self->{'lru'}))
269 12 2 if $diff >= 0
273 0 2 if $child