Branch Coverage

blib/lib/Data/Taxi.pm
Criterion Covered Total %
branch 59 88 67.0


line true false branch
192 1 0 if ($opts{'declaration'} or not defined $opts{'declaration'})
225 0 10 if (defined $opts{'tied'})
232 4 6 if (my $ref = ref $ob) { }
244 3 1 if (defined $opts{'name'})
248 1 3 if ($$ids{$ob})
261 0 3 unless ($ref =~ /^(HASH|ARRAY|REF|SCALAR)$/)
265 2 1 if ($ref eq 'HASH') { }
1 0 elsif ($ref eq 'ARRAY') { }
266 0 2 if (my $tie = tied %{$ob;})
274 0 1 if (my $tie = tied @{$ob;})
284 2 1 if ($tagname eq 'hashref') { }
1 0 elsif ($tagname eq 'arrayref') { }
0 0 elsif ($tagname eq 'scalarref') { }
288 0 6 if ($allowed and not exists $$allowed{$k})
317 3 3 if (defined $opts{'name'})
320 0 6 if (defined $opts{'tied'})
323 6 0 if (defined $ob)
357 1 0 if ($raw =~ s/^\<\?//)
372 4 0 unless ($raw =~ /$str/)
397 3 11 if ($el =~ m[^/])
399 1 2 if @stack == 1
414 0 11 unless $el =~ s/^([^\s\"]+)\s*//s
439 3 8 if ($tagname eq 'hashref') { }
1 7 elsif ($tagname eq 'arrayref') { }
0 7 elsif ($tagname eq 'scalarref') { }
6 1 elsif ($tagname eq 'scalar') { }
1 0 elsif (not $firstdone and $tagname eq 'taxi') { }
443 0 3 if (defined $atts{'tied'}) { }
467 0 1 if (defined $atts{'tied'}) { }
523 1 10 unless ($firstdone)
525 0 1 unless (exists $Data::Taxi::HANDLE_FORMATS{$atts{'ver'}})
533 1 9 if (defined $atts{'id'} and $ids{$atts{'id'}}) { }
0 9 elsif (defined $atts{'class'}) { }
6 3 elsif ($type == 4) { }
0 3 elsif ($type == 3) { }
551 4 6 if ($ref)
554 9 1 if (@stack) { }
0 1 elsif ($selfender) { }
559 6 3 if ($prevtype == 1) { }
3 0 elsif ($prevtype == 2) { }
579 1 0 if (not $selfender and $type == 1 || $type == 2 || $type == 3)
597 0 12 unless defined $rv
616 10 0 unless exists $$opts{'allowed'}
619 0 0 unless ref $$opts{'allowed'}