Branch Coverage

blib/lib/Dist/Metadata/Dist.pm
Criterion Covered Total %
branch 44 54 81.4


line true false branch
30 0 89 @_ == 1 ? :
36 5 84 if $req and not $$self{$req}
39 11 73 if (exists $$self{'file_spec'})
41 9 2 if $$self{'file_spec'}
44 3 8 unless $$self{'file_spec'}
83 2 34 unless @files
100 0 54 unless open my $fh, '>', $full_path
108 35 1 wantarray ? :
141 44 162 unless exists $$self{'file_spec'}
151 34 64 unless my $root = $self->root
155 0 64 if $file =~ m[^\Q$root\E[\\/]]
169 58 45 unless $$self{'_list_files'}
190 66 60 unless exists $$self{$method}
204 62 0 $self->path_class_file->new($_)->is_absolute ? :
205 41 0 if @files
233 76 37 if ($path)
235 54 22 if $path =~ m[ ([^\\/]+) # name (anything below final directory) - # separator (v?[0-9._]+) # version (?: # possible file extensions \.t(?:ar\.)?gz )? $ ]x
255 46 30 unless $dnifile =~ /\.[a-z]\w+$/
261 76 0 if ($dni_name and $dni_version or not $name)
262 76 0 if $dni_name
263 63 13 if $dni_version
266 0 76 if $@
307 0 58 unless @files
312 26 32 unless $files[0] =~ m[^([^\\/]+)[\\/]]
322 0 98 unless m[^\Q$dir\E[\\/](.+)$]
341 12 175 unless exists $$self{'root'}
353 87 139 if not exists $$self{$fields[$i]} and defined $values[$i]