Branch Coverage

blib/lib/Perl/Metrics/Simple/Analysis/File.pm
Criterion Covered Total %
branch 44 62 70.9


line true false branch
99 9 32 if (ref $path) { }
100 9 0 if (ref $path eq 'SCALAR') { }
106 0 32 unless (-r $path)
112 2 39 @LOGIC_KEYWORDS ? :
116 1 40 @LOGIC_OPERATORS ? :
120 0 41 @METHOD_MODIFIERS ? :
126 0 41 unless (defined $document)
149 29 3 if (-s $path) { }
192 0 41 unless ($document->isa("PPI::Document"))
215 0 218 unless $eval_result
216 0 218 unless defined $node
218 2 216 unless length $string
228 202 14 if (length $string)
230 99 103 if ($last_char ne "$Perl::Metrics::Simple::Analysis::File::INPUT_RECORD_SEPARATOR")
265 0 0 wantarray ? :
270 0 0 wantarray ? :
275 0 0 wantarray ? :
283 10 81 if ($self->get_node_length($elem) == 0)
287 81 0 if ($elem)
298 42 39 if ($operators_ref)
312 24 17 unless Perl::Metrics::Simple::Analysis::is_ref($found_packages, "ARRAY")
330 20 21 unless Perl::Metrics::Simple::Analysis::is_ref($found_subs, "ARRAY")
365 14 613 if ($grandparent->isa("PPI::Structure::Subscript"))
369 6 605 if ($sib->isa("PPI::Token::Operator") and $sib eq "=>")
380 0 259 unless (defined $document)
392 0 41 unless (defined $document)
403 8 0 if $_->[4]->isa("PPI::Token::Word")
409 8 0 if $_->[3]->isa("PPI::Token::Operator")
414 2 6 unless $_->[2]->isa("PPI::Token::Quote")
419 60 10 if $_->[1]->isa("PPI::Token::Word")
433 6 2 if ($children[1]->can('literal')) { }