Branch Coverage

blib/lib/Log/Scrubber.pm
Criterion Covered Total %
branch 87 104 83.6


line true false branch
58 1 9 if (not defined $val) { }
1 8 elsif (ref $val eq 'HASH') { }
4 4 elsif ($val) { }
63 1 0 if $_SDATA->{'enabled'}
75 6 0 unless (defined $old_sdata)
86 1 11 if ($_[$i] eq ':Carp') { }
1 10 elsif ($_[$i] eq ':Syslog') { }
0 10 elsif ($_[$i] =~ /^\+/) { }
1 9 elsif ($_[$i] =~ /^(dis|en)able$/) { }
97 1 0 $1 eq 'dis' ? :
99 0 1 if defined $change and $change != $val
108 8 1 if (not defined $change or $change) { }
119 6 5 $_SDATA->{'enabled'} ? :
147 10 78 if (ref $sub_msg eq 'ARRAY') { }
20 58 elsif (ref $sub_msg eq 'HASH') { }
9 49 elsif (ref $sub_msg) { }
149 5 30 if (ref $v) { }
151 5 13 if ("$v" eq $_)
152 0 5 unless $found
160 30 20 if (ref $sub_msg->{$k}) { }
162 5 51 if ("$sub_msg->{$k}" eq $_)
163 25 5 unless $found
176 25 74 unless defined $$sub_msg
178 1 256 ref $_SDATA->{'scrub_data'}{$_} eq 'CODE' ? :
187 0 300 ref $_SDATA->{'scrub_data'}{$_} eq 'CODE' ? :
199 34 8 if ($#$copy == 0)
208 0 0 if (defined $x)
210 0 0 if $_SDATA->{'scrub_data'}{$_} = $x->{$_}
217 9 0 if (defined $x)
219 0 18 if not defined $_ or $_ eq ''
230 17 8 if (defined $_SDATA->{'SIG'}{$_}{'scrubber'} and defined $SIG{$_} and $SIG{$_} eq $_SDATA->{'SIG'}{$_}{'scrubber'}) { }
1 7 elsif (defined $_SDATA->{'SIG'}{$_}{'old'}) { }
250 6 18 if (defined $_SDATA->{'SIG'}{$sig_name}{'old'} and $_SDATA->{'SIG'}{$sig_name}{'old'} ne '')
252 5 1 unless ($_SDATA->{'SIG_USED'}{$sig_name}{$code_str1})
258 15 4 if $sig_name eq '__WARN__'
259 4 15 if $sig_name eq '__DIE__'
266 18 21 unless $_SDATA->{'enabled'}
269 2 6 if defined $SIG{$sig_name} and defined $_SDATA->{'SIG'}{$sig_name}{'scrubber'} and $SIG{$sig_name} eq $_SDATA->{'SIG'}{$sig_name}{'scrubber'}
272 18 17 if $sig_name eq '__WARN__'
273 17 18 if $sig_name eq '__DIE__'
282 11 12 if ($_ eq 'WARN')
283 1 22 if ($_ eq '__WARN__')
284 9 14 if ($_ eq 'DIE')
285 2 21 if ($_ eq '__DIE__')
287 2 21 if defined $_SDATA->{'SIG'}{$sig_name}
300 23 6 if (defined $_SDATA->{'METHOD'}{$fullname}{'scrubber'} and defined $current_method and $current_method eq $_SDATA->{'METHOD'}{$fullname}{'scrubber'}) { }
0 6 elsif (defined $_SDATA->{'METHOD'}{$fullname}{'old'}) { }
318 23 20 unless $_SDATA->{'enabled'}
323 17 29 if ($fullname eq 'warnings::warnif')
325 0 46 unless (defined $r_orig)
334 0 25 if defined $_SDATA->{'METHOD'}{$fullname}
369 5 0 if (defined $x)