Branch Coverage

blib/lib/Perinci/Sub/DepChecker.pm
Criterion Covered Total %
branch 89 108 82.4


line true false branch
28 22 43 unless (defined &{"checkdep_$dname";})
32 22 0 unless defined &{"checkdep_$dname";}
36 22 21 if ($res)
49 7 4 if $res
58 4 12 unless check_deps($_)
61 5 1 $nfail ? :
68 4 6 unless $res
75 1 2 $ENV{$cval} ? :
80 1 1 &$cval() ? :
86 5 4 ref $cval eq 'HASH' ? :
87 0 9 unless my $prog_name = $cval->{'name'}
89 3 6 if ($prog_name =~ m[/]) { }
90 1 2 unless -x $prog_name
93 0 6 unless File::Which::which($prog_name)
98 4 4 if (defined $cval->{'min_version'})
104 2 2 if ($prog_name eq 'git') { }
2 0 elsif ($prog_name eq 'perl') { }
106 2 0 $_[0] =~ /git version (.+)/ ? :
109 2 0 $_[0] =~ /\(v(.+?)\)/ ? :
115 0 4 $? < 0 ? :
116 0 4 if $exit_code
118 0 4 unless ($ver) = &$ver_extract($ver)
120 2 2 if Version::Util::version_lt($ver, $cval->{'min_version'})
127 0 0 if $pa
136 0 0 unless $res->[0] == 200
138 0 0 unless $res->[2]{'type'} eq "package"
145 0 0 unless $res->[0] == 200
147 0 0 unless $res->[2]{'type'} eq "function"
168 57 42 if grep {$_ eq $el;} @$ary
173 8 2 if $_
6 4 if grep {$_ eq $el;} @$ary
184 42 238 if ($dname eq 'all') { }
42 196 elsif ($dname eq 'any') { }
63 133 elsif ($dname eq 'none') { }
187 1 41 unless @r
188 6 35 if grep {$_ eq "impossible";} @r
189 22 13 if grep {$_ eq "must";} @r and grep {$_ eq "must not";} @r
190 4 9 if grep {$_ eq "must";} @r
191 4 5 if grep {$_ eq "must not";} @r
192 3 2 if _all_nonblank_elems_is(\@r, "might")
196 1 41 unless @r
197 6 35 if grep {$_ eq "impossible";} @r
198 2 33 if _all_elems_is(\@r, "must")
199 2 31 if _all_elems_is(\@r, "must not")
200 2 29 if _all_elems_is(\@r, "")
205 1 62 unless @r
206 6 56 if grep {$_ eq "impossible";} @r
207 1 55 if grep {$_ eq "must";} @r and grep {$_ eq "must not";} @r
208 46 9 if grep {$_ eq "must";} @r
209 4 5 if grep {$_ eq "must not";} @r
210 3 2 if _all_nonblank_elems_is(\@r, "might")
212 107 26 if $dname eq $wanted
223 3 1 unless grep {$_ eq $dname;} @$res
224 1 3 if ($dname =~ /\A(?:all|any|none)\z/)