Branch Coverage

blib/lib/Tie/Cache.pm
Criterion Covered Total %
branch 56 122 45.9


line true false branch
100 1 1 if (ref $max_count)
105 0 2 unless ($max_count or $$options{'MaxBytes'})
109 0 2 exists $$options{'WriteSync'} ? :
111 0 2 $class ne 'Tie::Cache' ? :
147 0 2 if ($$self{'max_bytes'} and not $$self{'max_size'})
151 0 2 if ($$self{'max_bytes'} and $$self{'max_bytes'} < 1000)
155 0 2 if ($$self{'max_size'} and $$self{'max_size'} < 3)
181 15004 15001 if ($node) { }
186 15001 3 if (my $after = $$node[$Tie::Cache::AFTER]) { }
187 0 15001 if $$self{'dbg'} > 1
190 0 15001 if ($before) { }
204 0 3 unless $$self{'tail'} eq $node
208 0 15004 if $$self{'dbg'} > 1
220 0 15001 if ($$self{'subclass'})
221 0 0 if $$self{'dbg'} > 1
225 0 15001 if (defined $value) { }
227 0 0 if ($$self{'max_size'})
230 0 0 if ($length > $$self{'max_size'})
231 0 0 if $$self{'dbg'} > 1
249 0 30003 if $$self{'dbg'} > 1
252 10000 20003 unless defined $value
256 15003 5000 if ($$self{'max_size'})
258 0 15003 if ($length > $$self{'max_size'})
259 0 0 if ($$self{'subclass'})
260 0 0 if $$self{'dbg'} > 1
268 1 20002 if ($$self{'nodes'}{$key})
282 0 20003 if ($$self{'subclass'})
283 0 0 if ($$self{'sync'}) { }
284 0 0 if $$self{'dbg'} > 1
297 0 10001 if $$self{'dbg'} > 1
299 5001 5000 $node ? :
305 0 1 if $$self{'dbg'} > 1
307 0 1 if ($$self{'subclass'})
309 0 0 if $$self{'dbg'} > 1
354 0 0 if ($$self{'dbg'})
355 0 0 if ($$self{'hit'} or $$self{'miss'})
360 0 0 if ($$self{'dbg'} > 1)
365 0 0 if $$self{'dbg'} > 1
378 0 20003 unless defined $$key and defined $$value
382 15003 5000 if ($$self{'max_size'}) { }
383 15003 0 defined $length ? :
399 15000 15006 if $refs{$elem}
401 2 15004 if (ref $elem and ref($elem) =~ /^(SCALAR|HASH|ARRAY)$/) { }
404 0 2 if ($type eq 'SCALAR') { }
1 1 elsif ($type eq 'HASH') { }
1 0 elsif ($type eq 'ARRAY') { }
409 0 2 if (ref $kv) { }
418 0 1 if (ref $val) { }
438 0 20003 if $$self{'dbg'} > 1
446 20000 3 if ($$self{'tail'}) { }
457 0 5001 if ($$self{'dbg'} > 1)
464 0 5001 if ($$self{'subclass'})
465 0 0 if ($$old_node[$Tie::Cache::DIRTY])
466 0 0 if $$self{'dbg'} > 1
484 0 15003 if $$self{'dbg'} > 1
490 2 15001 if ($before) { }
496 15000 3 if ($after) { }
512 0 0 if $$self{'dbg'} > 1
517 0 0 if ($$node[$Tie::Cache::DIRTY])
518 0 0 if $$self{'dbg'} > 1
540 0 0 unless defined $$self{$_}