Condition Coverage

blib/lib/PPI/Xref.pm
Criterion Covered Total %
condition 90 147 61.2


and 3 conditions

line !l l&&!r l&&r condition
34 0 0 72 -d $dir && -r $dir && -w $dir
84 0 0 76 -d $d and -x $d
142 7409 4047 627 $prev_ws and $curr_ws
164 8 49 273 exists $self->{'file_packages'} and ref $self->{'file_packages'}{$file_id}
57 0 273 exists $self->{'file_packages'} and ref $self->{'file_packages'}{$file_id} and @{$self->{'file_packages'}{$file_id};}
188 0 2 154 defined $old_package and $old_package ne 'main'
204 36 64 0 $flatten_volume and $^O eq 'MSWin32'
326 0 0 36 defined $wrote and $wrote == $size
450 0 1 20 defined $hash_previous && defined $hash_current && $hash_previous eq $hash_current
564 85 6 0 $self->{'opt'}{'process_verbose'} and $self->{'opt'}{'recurse_verbose'}
587 130 0 56 defined $cache_filename and defined $hash_current
130 20 36 defined $cache_filename and defined $hash_current and not $hash_match
592 0 29 1 not $hash_match and defined $cached
699 0 532 26 defined $prev_package and $package ne $prev_package
711 1675 0 247 $elem->isa('PPI::Statement::Package') and @children >= 2
1218 0 457 $elem->isa('PPI::Statement::Sub') and defined $elem->name
1218 0 457 $elem->isa('PPI::Statement::Sub') and defined $elem->name and not $elem->forward
717 0 0 247 defined $package and length $package
773 650 0 201 $elem->isa('PPI::Statement::Include') and $stmt_content =~ /^(?:use|no|require)$/
650 28 173 $elem->isa('PPI::Statement::Include') and $stmt_content =~ /^(?:use|no|require)$/ and $include->isa('PPI::Token::Word')
28 0 173 $elem->isa('PPI::Statement::Include') and $stmt_content =~ /^(?:use|no|require)$/ and $include->isa('PPI::Token::Word') and not $include_content =~ /^v?5/
626 2 50 $stmt_content =~ /^(?:require|do)$/ and $include->isa('PPI::Token::Quote')
1387 0 0 0 defined $file_id and exists $self->{$key}{$file_id}
1467 2 2 8 defined $iterself->{'path'} and @{$iterself->{'path'};}
1522 0 2 0 defined $kind and $kind eq 'singleton'

or 2 conditions

line l !l condition
40 35 2 $opt //= {}
49 2 35 $opt->{'recurse'} //= 1
605 9 1 $self->{'__docscreated'} // 0
610 3 6 $self->{'__cachereads'} // 0
615 7 5 $self->{'__cachewrites'} // 0
620 4 2 $self->{'__cachecreates'} // 0
625 2 4 $self->{'__cacheupdates'} // 0
630 0 0 $self->{'__cachedeletes'} // 0
746 455 0 $package //= 'main'
981 0 4 $self->{'result_cache'}{'missing_modules'} //= []
982 0 4 $self->{'result_cache'}{'missing_modules_files'} //= {}
983 0 4 $self->{'result_cache'}{'missing_modules_count'} //= {}
1017 3 0 $self->{'modules'}{$module} || 0
1044 2 0 $self->{'missing_modules_count'}{$module} || 0
1051 0 2 $self->{'result_cache'}{'parse_errors_files'} //= []
1198 12 58 $opt->{'separator'} // "\t"
1263 0 7 $opt->{'separator'} // "\t"
1542 0 8 $opt->{'separator'} // "\t"

or 3 conditions

line l !l&&r !l&&!r condition
519 5 0 0 $fileloc // $file
534 4 0 0 $pseudo || -f $file
4 0 0 $pseudo || -s $file
552 42 246 0 $file //= $arg
698 507 51 0 $package{$scope_depth} // &first(sub { defined $_; } , @package{reverse 0 .. $scope_depth})
891 0 0 0 $self->{'opt'}{'process_verbose'} or $self->{'opt'}{'cache_verbose'}
1123 170 0 2 $PPI::Xref::a->[0] cmp $PPI::Xref::b->[0] or $FILE_BY_ID{$PPI::Xref::a->[1]} cmp $FILE_BY_ID{$PPI::Xref::b->[1]}
170 2 0 $PPI::Xref::a->[0] cmp $PPI::Xref::b->[0] or $FILE_BY_ID{$PPI::Xref::a->[1]} cmp $FILE_BY_ID{$PPI::Xref::b->[1]} or $PPI::Xref::a->[2] <=> $PPI::Xref::b->[2]
1244 6 5 0 $FILE_BY_ID{$PPI::Xref::a->[0]} cmp $FILE_BY_ID{$PPI::Xref::b->[0]} or $PPI::Xref::a->[1] <=> $PPI::Xref::b->[1]
11 0 0 $FILE_BY_ID{$PPI::Xref::a->[0]} cmp $FILE_BY_ID{$PPI::Xref::b->[0]} or $PPI::Xref::a->[1] <=> $PPI::Xref::b->[1] or $PPI::Xref::a->[2] <=> $PPI::Xref::b->[2]
1596 0 0 3 not $file =~ m[^/] or $file =~ /\.\./
0 0 3 not $file =~ m[^/] or $file =~ /\.\./ or not $file =~ /\.p[ml](?:\.cache)?$/