Branch Coverage

blib/lib/Data/Validator.pm
Criterion Covered Total %
branch 64 66 96.9


line true false branch
36 22 35 if (not Mouse::Util::TypeConstraints::HashRef($rule_ref)) { }
46 60 339 if exists $rule{$attr}
48 1 56 if ($used < keys %rule)
56 4 52 if (defined $rule{'xor'})
58 2 2 Mouse::Util::TypeConstraints::ArrayRef($rule{'xor'}) ? :
63 35 21 if (defined $rule{'isa'})
66 1 55 if (defined $rule{'does'})
67 1 0 if defined $rule{'type'}
73 33 22 if (defined $rule{'type'} and not defined $rule{'coerce'})
83 4 29 if (%xor)
103 0 27 if ref $role
116 2 1 if $$rule{'name'} eq $name
133 13 192 if exists $skip{$name}
135 123 69 if (exists $$args{$name}) { }
28 41 elsif (exists $$rule{'default'}) { }
35 6 elsif (not $$rule{'optional'}) { }
137 97 26 if (exists $$rule{'type'})
139 22 75 if ($err)
149 10 91 if ($$rule{'xor'})
152 4 14 if (exists $$args{$other_name})
168 2 26 Mouse::Util::TypeConstraints::CodeRef($default) ? :
178 27 82 if (@missing)
181 3 32 if exists $skip{$name}
184 4 28 if ($$rule{'xor'})
186 3 1 if exists $$args{$other_name}
190 1 28 @xors ? :
203 37 72 if ($used < $nargs)
205 7 30 if (keys %unknowns)
219 50 59 if (@errors)
231 18 55 !exists($knowns{$_}) ? :
261 74 23 if $tc->check($$args{$name})
263 2 21 if ($$rule{'coerce'})
265 1 1 if ($tc->check($value))