Branch Coverage

blib/lib/Cache/Moustache.pm
Criterion Covered Total %
branch 18 28 64.2


line true false branch
17 2 0 if {'Cache', 1, 'Cache::Cache', 1, 'Cache::FastMmap', 1, 'Cache::Moustache', 1, 'Cache::Ref', 1, 'CHI', 1, 'Mojo::Cache', 1}->{$what}
32 2 1 if ref $class and $class->isa('Cache::Moustache')
74 0 18 if $key =~ /^~~~~/
76 3 15 if ref $data and $$cache{'~~~~clone_references'}
78 14 4 unless defined $expires_in
80 0 18 if ($expires_in =~ /^(\d*)\s*([A-Za-z]+)$/)
83 0 0 unless defined $expires_in and length $expires_in
87 0 18 $expires_in < 0 ? :
94 0 14 if $key =~ /^~~~~/
95 3 11 unless exists $$cache{$key}
98 2 9 if ($expires_at >= 0 and $expires_at < time)
110 0 4 if $key =~ /^~~~~/
111 4 0 delete $$cache{$key} ? :
127 1 0 if $e >= 0