Branch Coverage

blib/lib/YAML/PP/Schema.pm
Criterion Covered Total %
branch 96 118 81.3


line true false branch
18 0 190 unless defined $bool
19 0 190 if (keys %args)
27 0 190 if ($b eq '*') { }
31 159 elsif ($b eq 'JSON::PP') { }
0 159 elsif ($b eq 'boolean') { }
159 0 elsif ($b eq 'perl') { }
0 0 elsif ($b eq 'perl_experimental') { }
87 121 173 @{$_[0]{'bool_class'};} ? :
104 148 72 if ($item eq "+")
108 10 210 if (&blessed($item))
127 1 209 if ($item =~ /^\:(.*)/) { }
129 0 1 unless ($class =~ /\A[A-Za-z0-9_:]+\z/)
136 0 209 unless ($class =~ /\A[A-Za-z0-9_:]+\z/)
156 4809 143 unless defined $implicit
158 4952 0 if ($tag)
159 56 4896 if (ref $tag eq 'Regexp') { }
169 4830 122 if ($implicit)
173 7874 1908 if ($type eq 'equals') { }
1426 482 elsif ($type eq 'regex') { }
482 0 elsif ($type eq 'all') { }
175 7874 0 unless (exists $res->{'equals'}{$match})
207 136 143 if ($tag and ref $tag eq 'Regexp') { }
143 0 elsif ($tag) { }
226 370 4467 if (my $flags = $args{'flags'})
231 186 4281 if (my $regex = $args{'regex'})
236 26 4255 if (my $regex = $args{'class_matches'})
241 31 4224 if (my $class_equals = $args{'class_equals'})
242 0 31 if ($] >= "5.036" and $class_equals eq "perl_experimental")
254 2 4222 if (my $class_isa = $args{'class_isa'})
259 0 4222 if (my $tied_equals = $args{'tied_equals'})
266 3941 281 if (defined(my $equals = $args{'equals'}))
273 24 257 if (defined(my $scalarref = $args{'scalarref'}))
279 24 233 if (defined(my $refref = $args{'refref'}))
285 24 209 if (defined(my $coderef = $args{'coderef'}))
291 24 185 if (defined(my $glob = $args{'glob'}))
297 185 0 if (my $undef = $args{'undefined'})
310 577 3838 if ($tag) { }
312 18 559 if (not $res and my $matches = $resolvers->{'tags'})
315 15 15 if ($tag =~ /$re/)
324 2096 1742 if ($event->{'style'} ne 1)
329 1808 511 if (my $equals = $res->{'equals'})
330 273 1535 if (exists $equals->{$value})
332 77 196 if (ref $res eq "CODE")
338 1506 540 if (my $regex = $res->{'regex'})
342 299 4580 if (@matches)
347 1537 210 if (my $catch_all = $res->{'all'})
348 1537 0 if (ref $catch_all eq "CODE")
363 21 783 if ($tag)
364 6 15 if (my $equals = $resolvers->{'tag'}{$tag})
367 6 0 if $on_create
370 15 0 if (my $matches = $resolvers->{'tags'})
374 14 2 if ($tag =~ /$re/)
376 14 0 if $on_create
393 55 533 if ($tag)
394 24 31 if (my $equals = $resolvers->{'tag'}{$tag})
397 23 1 if $on_create
400 31 0 if (my $matches = $resolvers->{'tags'})
404 28 66 if ($tag =~ /$re/)
406 28 0 if $on_create