Branch Coverage

Bio/DB/GFF/Adaptor/memory.pm
Criterion Covered Total %
branch 104 170 61.1


line true false branch
104 0 5 if defined $preferred_groups
107 0 5 if $file
108 0 5 if $fasta
115 0 0 if (-f $fasta and -w dirname($fasta) or -d $fasta and -w $fasta) { }
119 0 0 unless my $dna_db = eval { do { 'Bio::DB::Fasta'->new($fasta) } }
121 0 0 if $dna_db
130 0 120 if @_
145 0 120 if (my $dna_db = $self->dna_db)
148 0 120 unless $self->{'dna'}
150 5 115 unless defined $start or defined $stop
151 0 115 unless defined $start
154 55 60 if ($start > $stop)
159 55 60 if ($reversed)
189 0 175 if $feature_hash->{'strand'} and $feature_hash->{'strand'} eq '.'
190 0 175 if $feature_hash->{'phase'} and $feature_hash->{'phase'} eq '.'
191 0 175 unless length $feature_hash->{'gclass'} > 0
203 0 193 if ($name =~ /[*?]/)
220 6560 0 if (defined $feature->{'gname'}) { }
230 6170 390 if ($no_match_class_name)
233 6165 5 unless ($self->_matching_attributes($feature_attributes, $attributes))
242 8 185 unless (%refs)
254 0 185 if defined $refseq and lc $ref ne lc $refseq
259 0 395 if $strand and $strand eq '.'
260 185 210 if not defined $start or $start > $_->{'start'}
261 185 210 if not defined $stop or $stop < $_->{'stop'}
282 0 0 unless defined $feature->{'gclass'} and defined $feature->{'gname'}
283 0 0 unless $feature->{'attributes'}
292 0 0 unless $matches
301 0 0 if defined $limit and @results >= $limit
324 0 75 unless $_ >= 0 and $_ < @{$self->{'data'};}
339 10 11 if (@$ranges) { }
5 6 elsif (@$types) { }
340 5 5 @$types ? :
348 3 3 unless $force
378 20 30 if (defined $tag and lc $attr_name eq lc $tag) { }
15 15 elsif (not defined $tag) { }
389 0 5 unless $callback
401 10 55 if (lc $_ eq lc $attr_name and lc $attributes->{$_} eq lc $attr_value)
428 0 85 if $options->{'sort_by_group'}
462 0 16 unless $callback
466 0 16 if ($name =~ /[*?]/)
474 486 74 unless $regexp and $feature->{'gname'} =~ /$name/i or lc $feature->{'gname'} eq lc $name
475 0 74 if defined $feature->{'gclass'} and length $feature->{'gclass'} > 0 and $feature->{'gclass'} ne $class
477 0 74 if ($location)
478 0 0 if $location->[0] ne $feature->{'ref'}
479 0 0 if $location->[1] and $location->[1] > $feature->{'stop'}
480 0 0 if $location->[2] and $location->[2] < $feature->{'start'}
494 0 5 unless $callback
499 5 0 if ($type eq 'feature')
502 5 0 if $callback
512 25 0 unless ref $ids =~ /ARRAY/
518 0 25 wantarray ? :
528 0 15 unless $callback
562 525 350 if (defined $srcseq)
563 270 255 unless lc $feature_ref eq lc $srcseq
566 0 605 if (defined $class)
567 0 0 unless defined $feature_class and $feature_class eq $class
571 255 350 if (defined $start or defined $stop)
572 0 255 unless defined $start
573 0 255 unless defined $stop
574 0 255 unless $feature_stop >= $start and $feature_start <= $stop
577 0 605 if (defined $typelist and @$typelist)
578 0 0 unless $self->_matching_typelist($feature_method, $feature_source, $typelist)
587 15 10 $want_count ? :
624 2905 365 if (defined $refseq)
625 1940 965 unless lc $feature_ref eq lc $refseq
628 455 875 if (defined $start or defined $stop)
629 0 455 unless defined $start
630 0 455 unless defined $stop
632 385 70 if ($rangetype eq 'overlaps') { }
70 0 elsif ($rangetype eq 'contains') { }
0 0 elsif ($rangetype eq 'contained_in') { }
633 100 285 unless $feature_stop >= $start and $feature_start <= $stop
635 20 50 unless $feature_start >= $start and $feature_stop <= $stop
637 0 0 unless $feature_start <= $start and $feature_stop >= $stop
639 0 0 unless $feature_start == $start and $feature_stop == $stop
647 375 835 if (defined $types and @$types)
648 240 135 unless $self->_matching_typelist($feature_method, $feature_source, $types)
652 255 715 if (defined $attributes)
653 230 25 unless $self->_matching_attributes($feature_attributes, $attributes)
673 559 270 wantarray ? :
688 955 135 if lc $search_method ne lc $feature_method
689 0 135 if defined $search_source and lc $search_source ne lc $feature_source
698 6395 45 unless _match_all_attr_in_feature($_, $attributes->{$_}, $feature_attributes)
707 2360 45 if $attr_name ne $feature_attr_name or $attr_value ne $feature_attr_value