Branch Coverage

blib/lib/Data/FormValidator.pm
Criterion Covered Total %
branch 47 52 90.3


line true false branch
140 4 39 if ($defaults)
141 1 3 unless ref $defaults eq 'HASH'
147 39 3 if (ref $profiles_or_file) { }
322 99 60 unless (ref $self)
329 106 53 if (ref $name) { }
334 0 51 unless $profile
336 0 157 unless ref $profile eq 'HASH'
339 21 136 if ($self->{'defaults'})
349 2 142 if $self->{'defaults'}{'msgs'}
977 50 3 unless $file
979 1 2 unless -f $file
980 0 2 unless -r _
983 0 2 if $self->{'profiles'} and $self->{'profiles_mtime'} <= $mtime
987 1 1 unless ref $self->{'profiles'} eq 'HASH'
998 0 157 unless ref $profile eq 'HASH'
1037 3 856 unless grep(($key eq $_), @valid_profile_keys)
1041 2 155 if (@invalid)
1058 1 82 if (ref $val eq 'HASH' and not grep((ref $val->{'constraint_method'} eq $_), 'CODE', 'Regexp')) { }
2 80 elsif (not grep((ref $val eq $_), 'HASH', 'CODE', 'Regexp')) { }
1083 81 71 if $profile->{'constraints'}
1085 53 99 if $profile->{'constraint_regexp_map'}
1089 2 74 unless grep(($key eq $_), @valid_constraint_hash_keys)
1093 2 150 if (@invalid)
1110 15 135 if (ref $profile->{'msgs'} eq 'HASH')
1112 1 16 unless grep(($key eq $_), @valid_msgs_hash_keys)
1115 1 149 if (@invalid)