Branch Coverage

blib/lib/YATT/Lite/LRXML.pm
Criterion Covered Total %
branch 140 192 72.9


line true false branch
51 168 13 $tmpl->{'cf_public'} ? :
59 331 8 if $self->{'cf_vfs'}
78 58 281 if $self->{'cf_special_entities'}
114 0 0 ref $loadSpec ? :
115 0 0 unless (defined $loadType)
118 0 0 unless my $sub = $pack->can("load_${loadType}_into")
121 0 0 ref $tmplSpec ? :
131 0 19 unless defined $tmpl and UNIVERSAL::isa($tmpl, $pack->Template)
134 0 19 unless (defined $fn)
137 19 0 ref $pack ? :
138 0 19 unless open my $fh, '<', $fn
139 19 0 if $self->{'cf_encoding'}
151 174 6 ref $pack ? :
153 0 180 unless (defined $_[0])
157 7 170 if $self->{'cf_all'}
158 0 177 wantarray ? :
163 2 170 if $tmpl->{'parse_ok'}
177 638 187 if $sync
185 0 0 if $sync
192 3 177 if $tmpl->{'product'}
203 103 97 if length $1
205 10 190 if (my $comment_ns = $+{'comment'})
206 0 10 unless ($str =~ s/^(.*?)-->(\r?\n)?//s)
209 9 1 $2 ? :
220 93 97 if ($self->can("build_$kind")) { }
95 2 elsif (my $sub = $self->can("declare_$kind")) { }
223 0 93 unless (my $nameAtt = YATT::Lite::Constants::cut_first_att(\@args))
229 91 2 if ($nameAtt->[0] == 6) { }
2 0 elsif ($nameAtt->[0] == 8) { }
234 0 2 unless ($mapping = $self->parse_location($nameAtt->[5], $nameAtt->[4]))
246 2 91 if ($mapping)
261 0 187 unless ($str =~ s/^>([\ \t]*\r?\n)?//s)
268 0 187 unless ($1)
286 94 177 if ($prev)
287 0 94 unless (defined $part->{'cf_startpos'})
290 0 94 unless (defined $prev->{'cf_bodypos'})
295 263 8 if ($part->{'toks'} and @{$part->{'toks'};})
297 247 16 if ($part->{'toks'}[-1] =~ s/(?:\r?\n)+\Z//)
299 244 3 unless $tmpl->{'cf_ignore_trailing_newlines'}
302 269 2 if (my $sub = $part->can('fixup'))
306 177 0 if ($prev)
315 2 175 if ($self->{'rootroute'})
318 2 175 if ($self->{'subroutes'})
334 549 537 if $+{'ws'} or $+{'comment'}
335 12 525 if $+{'nestclo'}
336 0 525 if $+{'macro'}
339 312 213 if (not $+{'attname'} and $+{'bare'} and is_ident($+{'bare'})) { }
12 201 elsif ($+{'nest'}) { }
1 200 elsif ($+{'entity'} or $+{'special'}) { }
346 0 1 if ($+{'lcmsg'})
356 91 109 !$quote && is_ident($value) ? :
108 92 $for_decl ? :
361 743 331 if $self->{'cf_debug'}
363 389 0 wantarray ? :
370 249 2 if (my $ns = $+{'entity'}) { }
2 0 elsif (my $special = $+{'special'}) { }
382 18 494 unless defined(my $value = shift())
386 7 487 @names > 1 ? :
395 252 6 @$chunks && !ref($chunks->[0]) ? :
405 333 165 if (length $_)
406 333 0 if $sink
414 10 0 if $sink
418 252 246 unless @$chunks
435 0 1990 unless (defined $pos)
439 0 1990 unless (defined $tok)
442 0 1990 unless ($tok eq $_[0])
487 0 89 unless ($oldpart->{'cf_implicit'})
490 88 1 if (@{$tmpl->{'partlist'};} == 1) { }
503 2 80 if (@_ and $_[0] and $_[0][0] == 8 and not defined $_[0][4])
507 0 2 unless (my $mapping = $self->parse_location($patNode->[5], '', $newpart))
544 0 4 unless $location =~ m[^/]
561 0 180 if (not $self->{'cf_namespace'}) { }
569 0 339 unless defined $self->{'cf_namespace'}
572 339 0 ref $self->{'cf_namespace'} && wantarray ? :
578 0 362 if (defined $tmpl->{'Item'}{$part->{'cf_name'}})
583 94 268 if ($tmpl->{'partlist'} and my YATT::Lite::Core::Part $prev = $tmpl->{'partlist'}[-1])
610 0 263 unless (defined $argName)
613 0 263 if (exists $part->{'arg_dict'}{$argName})
618 11 252 if ($node_type == 9) { }
625 25 238 defined $default ? :
630 11 251 if ($node_type == 9) { }
636 0 11 unless my $sub = $self->can("add_arg_of_type_$t")
677 1 1 @subtype ? :
679 0 2 unless (&Scalar::Util::isweak($var->[7]))
685 0 4 if $widget->{'arg_dict'}{$argName}
697 106 165 $part->{'arg_order'} ? :
709 10 10 if (my $vfs = $self->{'cf_vfs'}) { }
718 3 17 $self->{'cf_path'} ? :
10 10 defined $ln ? :
724 0 419 unless defined $_[0]
733 200 179 if (defined(my $value = $hash->{$key}))
742 180 0 ref $_[0] ? :
745 257 171 unless defined $_[0] and length $_[0]
771 0 8 unless (ref $_[0])
776 0 8 unless my $sym = $YATT::Lite::LRXML::{$meth}
787 0 8 unless my $code = *{$sym;}{'CODE'}