Condition Coverage

blib/lib/App/perlimports/Document.pm
Criterion Covered Total %
condition 71 90 78.8


and 3 conditions

line !l l&&!r l&&r condition
400 45 359 4 not $word->isa("PPI::Token::Symbol") and is_method_call($word)
508 388 0 14 $child->isa("PPI::Structure::List") and not defined $imports
557 0 1 2 $words and scalar @$words == 1
1 1 1 $words and scalar @$words == 1 and $full_cast =~ /([\$\@\%])\{$words->[0]}/
607 1766 25 8 $_[1]->isa("PPI::Token::Quote") and not $_[1]->isa("PPI::Token::Quote::Single")
655 0 0 2 $cast->snext_sibling and $cast->snext_sibling->isa("PPI::Structure::Block")
712 0 0 11 $children[0] eq "sub" and $children[1]->isa("PPI::Token::Word")
737 0 53 1 exists $self->original_imports->{$module_name} and &any(sub {
758 2346 77 6 $_[1]->isa("PPI::Token::Symbol") and $_[1] =~ /\A[*\$\@\%]+$module_name::[a-zA-Z0-9_]/
1996 436 1 $_[1]->isa("PPI::Token::Word") and $_[1]->content =~ /\A$module_name::[a-zA-Z0-9_]*\z/ || $_[1]->content eq $module_name && $_[1]->snext_sibling eq '->'
870 39 2 1 not $self->_preserve_duplicates and exists $processed{$include->module}
919 1 5 9 $args[0] and $args[0] eq "()"
6 7 2 $args[0] and $args[0] eq "()" and not $self->_is_used_fully_qualified($include->module)
1087 0 0 0 defined $ENV{'HOME'} && -d path($ENV{'HOME'}, '.cache')
1133 0 45 359 $word->statement and $word->isa("PPI::Token::Word")
1137 353 5 1 is_hash_key($word) and @children == 1
1152 309 3 4 $current->isa("PPI::Token::Operator") and $current->content eq "=>"

or 2 conditions

line l !l condition
372 36 15 $self->_ppi_selection->find(sub {
385 34 0 $self->ppi_document->find(sub {
445 41 0 $self->ppi_document->find(sub {
480 1 31 $self->ppi_document->find(sub {
540 4 10 $doc->find('PPI::Token::Cast') || []
554 3 0 $cast_as_doc->find('PPI::Token::Word') || []

or 3 conditions

line l !l&&r !l&&!r condition
327 31 0 1 not $pkgs or $pkgs->[0]->namespace eq "main"
512 43 8 351 $child->isa("PPI::Token::QuoteLike::Words") or $child->isa("PPI::Token::Quote::Single")
578 1 2 9 not $token->isa("PPI::Token::Quote") or $token->isa("PPI::Token::Quote::Single")
607 8 0 1791 $_[1]->isa("PPI::Token::Quote") and not $_[1]->isa("PPI::Token::Quote::Single") or $_[1]->isa("PPI::Token::Quote::Interpolate")
8 0 1791 $_[1]->isa("PPI::Token::Quote") and not $_[1]->isa("PPI::Token::Quote::Single") or $_[1]->isa("PPI::Token::Quote::Interpolate") or $_[1]->isa("PPI::Token::QuoteLike::Regexp")
617 1 0 8 $token->isa("PPI::Token::Regexp") or $token->isa("PPI::Token::QuoteLike::Regexp")
758 3 1 433 $_[1]->content =~ /\A$module_name::[a-zA-Z0-9_]*\z/ || $_[1]->content eq $module_name && $_[1]->snext_sibling eq '->'
793 4 7 56 exists $default_ignore{$element->module} || exists $self->_ignore_modules->{$element->module} || $self->_annotations->is_ignored($element) || &any(sub {
1073 5 2 0 $next->isa("PPI::Token::Whitespace") or $next->isa("PPI::Token::Comment")