Branch Coverage

blib/lib/PomBase/Chobo/OntologyTerm.pm
Criterion Covered Total %
branch 50 60 83.3


line true false branch
75 90 6 if $_ ne "id"
94 39 4 if ($val =~ /(\S+):(\S+)/) { }
102 0 4 if (defined $self->metadata->{'ontology'} and $self->metadata->{'ontology'} eq 'ro') { }
151 0 88 unless (defined $object)
155 11 46 if ($object->{'def'} and $object->{'def'}{'dbxrefs'} and $object->{'alt_id'})
168 2 4 if ($object->{'is_obsolete'} and $object->{'name'} and not $object->{'name'} =~ /^obsolete/i)
172 14 0 if ($object->{'is_relationshiptype'} and $object->{'name'})
178 81 7 if ($options)
179 40 41 if ($options->{'namespace_from_metadata'})
188 10 78 unless (($db_name, $accession) = $object->{'id'} =~ /^(\S+):(.+?)\s*$/)
189 0 10 if ($object->{'id'} eq 'part_of') { }
208 0 88 unless (defined $object->{'source_file'})
212 0 88 unless (defined $object->{'source_file_line_number'})
237 1 14 if $self == $other_term
242 0 14 if (scalar $lc->get_intersection == 0)
256 32 0 if (defined $field_conf) { }
257 18 14 if (defined $field_conf->{'type'} and $field_conf->{'type'} eq 'SINGLE' || $field_conf->{'type'} eq 'SINGLE_HASH') { }
260 9 9 if (defined $field_conf->{'merge'})
264 2 16 if (defined $res) { }
269 12 4 if (defined $new_field_value) { }
270 9 3 if (not defined $self->{$name} or $name eq 'namespace' and $self->{'_namespace_from_metadata'}) { }
275 3 0 if ($name ne "namespace" or not $other_term->{'_namespace_from_metadata'})
296 9 1 unless (grep {Compare($_, $single_value);} @{$$self{$name};})
307 28 196 if $field_name eq "id" or $field_name eq "alt_id"
309 32 164 unless (Compare($self->{$field_name}, $other_term->{$field_name}))
323 0 12 if ($self->is_relationshiptype) { }
335 26 34 if (ref $value) { }
337 2 24 if ($field_conf{$name}{'type'} eq 'SINGLE_HASH') { }
345 19 21 if (defined $to_string_proc) { }
362 60 132 if (defined $field_value)