Branch Coverage

blib/lib/DBG.pm
Criterion Covered Total %
branch 68 114 59.6


line true false branch
36 0 1 $ENV{'DBG_LOG'} eq '0' ? :
1 0 defined $ENV{'DBG_LOG'} ? :
40 1 40 unless $ON
42 0 40 unless defined $data
43 1 39 if ($HEADER and not $stamped)
48 1 0 if $fh
54 40 0 if $fh
59 1 0 if (length $fn)
60 0 1 unless $fh = 'FileHandle'->new(">> $fn")
68 1 0 if ($HEADER and $stamped)
73 1 0 if $fh
89 1 5 if defined $text
96 0 3 if $self->can('SUPER::DESTROY')
109 0 2 unless $ON
111 0 4 unless &blessed($_) and $_->isa('DBG::ts')
119 1 1 if (defined $text)
124 10 0 unless $amt
126 0 0 if $amt == 1
129 2 0 unless $reported
135 0 1 unless $ON
152 0 3 unless $ON
171 0 4 if ($error) { }
182 0 1 unless $ON
189 0 3 unless $ON
193 2 1 if (@frame and $msg) { }
197 1 0 @frame ? :
199 1 1 if $msg and ref $msg || $msg ne '1'
205 0 1 unless $ON
213 0 3 unless $type
218 1 2 if ($hash->{$addr}++) { }
225 2 0 if ($type eq 'HASH') { }
0 0 elsif ($type eq 'ARRAY') { }
238 1 1 $var ? :
244 0 1 unless ref $code
247 1 0 if (my $st = $gv->STASH)
251 1 0 if ($n)
253 1 0 if ($n eq '__ANON__')
257 1 0 unless $quiet
263 0 9 unless my $cv = svref_2object($code)
265 0 9 unless $cv->isa('B::CV') and my $gv = $cv->GV
273 0 2 unless &blessed($obj)
274 0 2 unless defined $method
276 0 2 unless $m
278 0 2 unless $gv
279 1 1 if (not $file) { }
291 2 0 if ($ts) { }
293 1 1 if @_
304 2 0 if (my $class = ref $obj) { }
307 1 1 if ($verbose) { }
311 2 4 if $l > $longest
319 3 3 if ($gv->LINE) { }
345 0 1 unless length($class // '')
365 0 1 unless ref $ref eq 'CODE'
373 1 0 unless shift()
379 1 1 if &blessed($i)
381 1 0 if ($_ eq 'HASH') { }
0 0 elsif ($_ eq 'ARRAY') { }