Branch Coverage

blib/lib/Bio/DB/USeq.pm
Criterion Covered Total %
branch 158 338 46.7


line true false branch
890 2 0 if (@_)
891 1 1 if ($_[0] =~ /^-/) { }
901 2 0 if ($file)
902 0 2 unless $self->open($file)
914 0 2 unless ($filename)
918 0 2 unless ($filename =~ /\.useq$/i)
922 0 2 if ($self->slices)
930 0 2 unless ($error == 0)
938 0 2 unless $self->_parse_members
947 0 1 unless $self->{'zip'}
951 0 1 unless ($error == 0)
978 0 7 unless my $seq_id = shift()
979 7 0 if (exists $self->{'seq_ids'}{$seq_id})
990 0 0 unless %{$self->{'metadata'};}
997 0 1 unless $key
998 1 0 unless %{$self->{'metadata'};}
999 1 0 if (exists $self->{'metadata'}{$key})
1019 0 1 unless my $seq_id = shift()
1021 0 1 unless %{$self->{'metadata'};}
1024 0 1 if (exists $self->{'metadata'}{"chromStats_$seq_id"})
1049 0 1 unless $self->slice_type($slice) =~ /f/
1061 9151 0 if (defined $r->[2])
1065 4 9147 if not defined $min or $r->[2] < $min
1066 33 9118 if not defined $max or $r->[2] > $max
1083 1 0 unless $delay_write
1090 0 1 unless my $seq_id = shift()
1096 0 0 unless my $seq_id = shift()
1104 0 0 unless %{$self->{'metadata'};}
1107 0 0 if (exists $self->{'metadata'}{'globalStats'})
1130 0 0 if not defined $min or $stats->{'minVal'} < $min
1131 0 0 if not defined $max or $stats->{'maxVal'} > $max
1170 0 0 unless my $slice = shift()
1176 0 1088 unless my $slice = shift()
1182 0 2021 unless my $slice = shift()
1188 0 4 unless my $slice = shift()
1194 0 1020 unless my $slice = shift()
1200 0 6 unless my $slice = shift()
1206 0 0 unless my $slice = shift()
1229 0 1 unless $self->length($seq_id)
1249 0 2 if (ref $args{'-type'} and ref $args{'-type'} eq 'ARRAY') { }
1258 0 2 if ($type =~ /chromosome/) { }
2 0 elsif ($type =~ /region|interval|observation|coverage|wiggle|summary/) { }
1270 0 0 wantarray ? :
1280 0 2 unless $iterator
1283 0 0 if (exists $args{'-iterator'} and $args{'-iterator'})
1292 2 0 wantarray ? :
1332 0 0 unless @list
1333 0 0 if scalar @list == 1
1335 0 0 if $f->start == $start and $f->end == $end
1351 0 3 unless $self->length($seq_id)
1357 0 3 if (ref $args{'-type'} and ref $args{'-type'} eq 'ARRAY') { }
1381 0 1 unless $self->length($seq_id)
1386 0 1 unless @slices
1401 31 0 if defined $r->[2]
1405 1 0 wantarray ? :
1413 0 0 unless $self->length($seq_id)
1418 0 0 unless @slices
1432 0 0 wantarray ? :
1445 0 1 unless ($readMe)
1454 0 5 if (/^#/)
1455 0 0 unless $_ =~ /validCount/
1458 5 0 if (/^\s*([^=\s]+)\s*=\s*(.+)\s*$/)
1479 2 6 if $member eq "archiveReadMe.txt"
1486 0 6 unless ($chromo and $strand and defined $start and defined $stop and $number and $extension)
1493 2 4 unless (defined $self->{'stranded'})
1494 1 1 if ($strand eq '.') { }
1505 3 3 if (exists $self->{'seq_ids'}{$chromo}) { }
1506 3 0 if ($stop > $self->{'seq_ids'}{$chromo})
1515 1 0 $strand eq '-' ? :
4 1 $strand eq '.' ? :
1 5 $strand eq '+' ? :
1520 0 6 if ($start >= $stop)
1535 0 2 if (@errors)
1538 0 2 unless (%{$self->{'coord2file'};})
1551 5 0 if ($_[0] =~ /^\-/) { }
1561 0 5 unless ($seq_id)
1575 0 6 unless exists $self->{'coord2file'}{$seq_id}
1579 6 0 if ($strand == 0) { }
1582 1 5 if $self->stranded
1587 0 0 unless $self->stranded
1592 1 5 if ($both) { }
1618 4 1 unless exists $wanted{$_}
1625 1009 7 if exists $self->{'buffer'}{$slice}
1634 0 7 if ($type eq 's') { }
0 7 elsif ($type eq 'sf') { }
0 7 elsif ($type eq 'st') { }
0 7 elsif ($type eq 'ss') { }
6 1 elsif ($type eq 'ssf') { }
0 1 elsif ($type eq 'sst') { }
1 0 elsif ($type eq 'ssft') { }
0 0 elsif ($type eq 'i') { }
0 0 elsif ($type eq 'if') { }
0 0 elsif ($type eq 'it') { }
0 0 elsif ($type eq 'ii') { }
0 0 elsif ($type eq 'iif') { }
0 0 elsif ($type eq 'iit') { }
0 0 elsif ($type eq 'iift') { }
0 0 elsif ($type eq 'is') { }
0 0 elsif ($type eq 'isf') { }
0 0 elsif ($type eq 'ist') { }
0 0 elsif ($type eq 'isft') { }
2172 0 1000 unless @$slices
2178 0 1001 unless $self->slice_type($slice) =~ /f/
2191 1000 0 $count ? :
2197 0 10 unless @$slices
2208 0 11 unless $self->slice_type($slice) =~ /f/
2218 11994 0 if (defined $r->[2])
2222 40 11954 if not defined $min or $r->[2] < $min
2223 111 11883 if not defined $max or $r->[2] > $max
2241 0 1 unless -w $self->zip->fileName
2247 1 0 if exists $md->{'comments'}
2253 5 2 if /useqArchiveVersion|dataType|versionedGenome|comments|chromStats|globalStats/
2260 0 1 if exists $md->{'globalStats'}
2262 1 6 if /chromStats/
2277 0 2 unless $score->{'validCount'}
2283 0 1 unless $score->{'validCount'}
2285 1 0 if ($score->{'validCount'} > 1)
2288 0 1 if $var < 0
2321 0 0 unless exists $self->{'useq'}
2327 0 0 unless exists $self->{'useq'}
2333 0 0 unless exists $self->{'useq'}
2339 0 0 unless exists $self->{'useq'}
2345 0 0 unless exists $self->{'useq'}
2351 0 0 unless exists $self->{'useq'}
2365 1 0 if exists $args{'-useq'}
2412 0 0 wantarray ? :
2455 0 4 unless my $useq = $args{'-useq'}
2470 3 1 if (scalar @slices > 1)
2479 2 2 if ($iterator->type =~ /region|interval|observation/)
2493 1 1 $iterator->type =~ /summary/ ? :
2497 0 2 if ($iterator->strand == 0 and $useq->stranded) { }
2502 0 0 if ($useq->slice_strand($_) == 1) { }
2518 1 1 if ($iterator->type =~ /:(\d+)$/i)
2521 0 1 if $bin > $length
2533 2 8 if ($self->{'wiggle'} == 1) { }
2 6 elsif ($self->{'wiggle'} == 2) { }
2553 2 4 unless ($self->{'current_results'})
2555 0 2 unless $slice
2562 0 291 unless $Bio::DB::USeq::Iterator::a->[0] <=> $Bio::DB::USeq::Iterator::b->[0]
2569 0 6 unless (defined $obs)
2578 5 1 defined $obs->[3] ? :
2595 1 1 unless $slices
2604 1 0 if ($self->{'bin'} and $step > 1) { }
2616 1000 0 if (scalar @$slices > 1) { }
2621 939 1061 if $s > $useq->slice_end($slice)
2622 60 1001 if $e < $useq->slice_start($slice)
2656 0 0 exists $pos2score{$s} ? :
2664 0 1 $strand == -1 ? :
0 1 $strand == 1 ? :
2684 1 1 unless $slices
2702 0 1 $strand == -1 ? :
0 1 $strand == 1 ? :
2716 0 1 unless my $useq = $args{'-useq'}
2725 1 0 wantarray ? :
2752 0 0 if $bins and $bins > 1
2764 0 0 unless defined $s
2767 0 0 if not defined $min or $s < $min
2768 0 0 if not defined $max or $s > $max
2805 0 1 unless my $useq = $args{'-useq'}
2808 1 0 if exists $args{'-slices'}
2809 1 0 if exists $args{'-bin'}
2810 1 0 if exists $args{'-step'}
2820 1 0 if exists $self->{'bin'}
2822 1 0 if exists $self->{'step'}
2826 1 0 if exists $self->{'slices'}
2827 0 1 unless ($slices)
2845 10 0 if (scalar @$slices > 1) { }
2850 0 20 if $s > $useq->slice_end($slice)
2851 9 11 if $e < $useq->slice_start($slice)