Branch Coverage

blib/lib/Module/CPANTS/Kwalitee/License.pm
Criterion Covered Total %
branch 21 52 40.3


line true false branch
24 3 8 if ($yaml)
25 3 0 if ($yaml->{'license'} and $yaml->{'license'} ne 'unknown')
35 0 11 if (my($file) = grep({$_ =~ /^(?:LICEN[CS]E|COPYING)\b/;} @$files))
44 0 9 unless -r $path
45 0 9 unless open my $fh, '<', $path
54 0 33 if ($first_four eq '=hea' and ($uc_head = uc $_) =~ /(?:LICEN[CS]E|LICEN[CS]ING|COPYRIGHT|LEGAL)/) { }
2 31 elsif ($first_four eq '=hea' or $first_four eq '=cut') { }
0 31 elsif ($in_pod) { }
57 0 0 if ($in_pod)
59 0 0 if (@guessed) { }
71 0 2 if ($in_pod)
73 0 0 if (@guessed) { }
86 0 9 if ($pod)
88 0 0 if (@guessed) { }
94 0 9 if (@possible_licenses) { }
99 0 9 if @unknown_license_texts
102 0 11 if (%licenses)
105 0 0 if (@possible_licenses == 1)
129 3 8 $yaml->{'license'} && $yaml->{'license'} ne 'unknown' ? :
133 0 0 unless $yaml
134 0 0 unless $yaml->{'license'}
144 0 11 $d->{'external_license_file'} || $d->{'license_in_pod'} ? :
156 0 11 +(shift())->{'external_license_file'} ? :
168 0 11 $d->{'license_in_pod'} ? :
182 11 0 unless $d->{'license_in_pod'}
184 0 0 @files_with_licenses ? :