Branch Coverage

blib/lib/MARC/Convert/Wikidata/Transform.pm
Criterion Covered Total %
branch 44 72 61.1


line true false branch
54 0 5 unless (defined $self->{'marc_record'})
57 0 5 unless (&blessed($self->{'marc_record'}) and $self->{'marc_record'}->isa("MARC::Record"))
97 0 5 unless (defined $ccnb)
113 3 39 if ($k->url =~ m[$authority/$]ms)
135 0 2 unless (defined $cover)
138 0 2 if ($cover ne 'hardback' and $cover ne 'paperback') { }
145 0 5 if (@ret_cover > 1)
160 0 4 if ($uri =~ m[https://dml\.cz/handle/10338\.dmlcz/(\d+)$]ms)
172 0 7 unless (defined $edition_number)
178 3 4 if (not defined $edition_number) { }
0 4 elsif (not $edition_number =~ /^\d+$/ms) { }
194 1 1 unless (defined $isbn)
201 0 1 unless (defined $pub)
204 1 0 if (&any(sub {
210 1 0 defined $cover ? :
0 1 defined $publisher ? :
221 1 0 if (defined $isbn_o)
249 4 1 unless (@lang)
273 0 5 if (@oclc > 1)
285 0 5 if ($publication_date =~ /^(\d+)\-(\d*)$/ms)
287 0 0 if ($2)
321 0 5 $self->_dml ? :
2 3 $self->_edition_number ? :
334 6 0 if (defined $type_key)
338 1 6 unless (@type_keys)
350 6 0 if (defined $dates)
395 0 6 if (not defined $type or $type eq "")
400 6 0 if (exists $PEOPLE_TYPE{$type}) { }
412 9 9 unless (defined $field)
422 9 0 if (defined $places[$i]) { }
442 5 0 unless ($publication_date)
449 5 0 wantarray ? :
489 19 57 unless (defined $field_value)
502 4 1 if (defined $subtitle)
507 0 5 if (defined $number_of_part)
512 0 5 if (defined $name_of_part)