Condition Coverage

blib/lib/Validate/Tiny.pm
Criterion Covered Total %
condition 56 71 78.8


and 3 conditions

line !l l&&!r l&&r condition
160 6 14 17 defined $_[0] and $_[0] ne ''
169 2 1 0 ref $condition and ref $condition ne 'CODE'
179 0 2 2 defined $value and $value ne ''
197 0 2 1 defined $_[1]{$other} and $_[0] eq $_[1]{$other}
207 1 2 2 length $_[0] >= $min and length $_[0] <= $max
266 5 0 1 defined $filters and ref $filters eq 'HASH'

or 2 conditions

line l !l condition
158 1 9 shift() || 'Required'
168 1 2 $err_msg ||= 'Required'
185 1 1 shift() || 'Must be defined'
194 1 2 $err_msg ||= 'Invalid value'
234 1 1 $err_msg ||= 'Invalid value'
243 1 2 $err_msg ||= 'Invalid value'
254 1 2 $err_msg ||= 'Invalid value'

or 3 conditions

line l !l&&r !l&&!r condition
50 2 2 127 ref $$rules{$_} ne 'ARRAY' or @{$$rules{$_};} % 2
72 0 49 0 $$error{$key} ||= $err
196 0 1 3 not defined $_[0] or $_[0] eq ''
204 1 1 0 $err_msg ||= "Must be between $min and $max symbols"
206 0 1 5 not defined $_[0] or $_[0] eq ''
214 1 1 0 $err_msg ||= "Must be at least $length symbols"
216 0 1 3 not defined $_[0] or $_[0] eq ''
224 1 1 0 $err_msg ||= "Must be at the most $length symbols"
226 0 1 4 not defined $_[0] or $_[0] eq ''
236 1 1 3 not defined $_[0] or ref $_[0] eq $class
246 0 1 4 not defined $_[0] or $_[0] eq ''
257 0 1 4 not defined $_[0] or $_[0] eq ''
278 1 1 4 ref $input ne 'HASH' or ref $rules ne 'HASH'