Branch Coverage

blib/lib/CPAN/PackageDetails.pm
Criterion Covered Total %
branch 42 76 55.2


line true false branch
127 0 24 if (exists $args{'dbmdeep'}) { }
129 0 0 if ($@)
136 0 0 unless ref $ref
209 19 5 if defined &{"${class}::$method";} or exists $Dispatchable{$method} or $self->header_exists($method)
222 0 1616 unless ref $self
225 1602 14 if (exists $Dispatchable{$method}) { }
13 1 elsif ($self->header_exists($method)) { }
281 24 0 unless exists $self->{'entries'}
285 24 0 unless exists $self->{'header'}
317 1 6 unless (defined $file)
324 1 5 unless (my $fh = 'IO::Uncompress::Gunzip'->new($file))
352 4 40 if /\A\s*\Z/
390 1 3 unless (defined $output_file)
397 1 2 unless (my $fh = 'IO::Compress::Gzip'->new("$output_file.$$"))
405 0 2 unless (rename "$output_file.$$", $output_file)
485 0 4 unless (-e $file)
500 0 4 unless ($header_count)
507 1 3 unless ($header_count == $entries_count)
514 4 0 if ($cpan_path)
518 2 2 if @$missing_in_file
519 1 3 if @$missing_in_repo
523 3 1 if $error->{'error_count'}
551 2 5 unless -e $native_path
602 15 10 if (not exists $Seen{$name}) { }
9 1 elsif ($Seen{$name}[2] lt $version) { }
610 15 10 if (exists $Seen{$_}) { }
625 0 0 unless my $file = shift()
627 0 0 unless my($dist, $version) = $file =~ /^ ( # start of dist name (?: [-+.]* (?: [A-Za-z0-9]+ | (?<=\D)_ | _(?=\D) )* (?: [A-Za-z] (?= [^A-Za-z] | $ ) | \d (?=-) ) (?
663 0 0 if $dist =~ /-undef\z/ and not length $version
667 0 0 if ($version =~ /^(-[Vv].*)-(\d.*)/)
672 0 0 if not length $version and $dist =~ s/-(\d+\w)$//
674 0 0 if $version =~ /^\d+$/ and $dist =~ s/-(\w+)$//
676 0 0 if ($version =~ /\d\.\d/) { }
685 0 0 if (length $version) { }
687 0 0 if ($file =~ /^perl-?\d+\.(\d+)(?:\D(\d+))?(-(?:TRIAL|RC)\d+)?$/) { }
0 0 elsif ($version =~ /\d\D\d+_\d/) { }
688 0 0 if $1 > 6 and $1 & 1 or $2 and $2 >= 50 or $3
710 16 16 if /\.(?:tar\.gz|tgz|zip)\z/