Branch Coverage

blib/lib/Data/Password/zxcvbn/Match/Date.pm
Criterion Covered Total %
branch 43 48 89.5


line true false branch
23 1 369 if $self->separator
87 481 1052 if $length < 4
93 5304 14105 if $j >= $length
96 12204 1901 unless $token =~ /$MAYBE_DATE_NO_SEP_RE/x
99 0 1901 unless $SPLITS{length $token}
102 2343 2111 unless my $year = $class->_map_ints_to_year(substr($token, 0, $k), substr($token, $k, $l - $k), substr($token, $l))
110 490 1411 unless @candidates
132 3499 6158 if $j >= $length
135 5980 178 unless my(@pieces) = $token =~ /$MAYBE_DATE_WITH_SEP_RE/x
138 30 148 unless my $year = $class->_map_ints_to_year($pieces[0], $pieces[2], $pieces[3])
167 2624 8448 $_->i <= $match->i && $_->j >= $match->j ? :
1559 11072 $_ == $match ? :
189 1229 3403 if $ints[1] > 31 or $ints[1] <= 0
192 9625 584 unless $_ > $MAX_YEAR
769 2634 if grep {$_ > 99 and $_ < $MIN_YEAR unless $_ > $MAX_YEAR;} @ints
195 0 2634 if grep {$_ > 31;} @ints >= 2
197 0 2634 if grep {$_ == 0;} @ints >= 2
199 0 2634 if grep {$_ > 12;} @ints == 3
208 335 4763 if ($year >= $MIN_YEAR and $year <= $MAX_YEAR)
212 255 80 if ($class->_map_ints_to_dm(@rest)) { }
226 2004 1108 if ($class->_map_ints_to_dm(@rest))
239 2259 1483 if ($d >= 1 and $d <= 31 and $m >= 1 and $m <= 12)
248 0 2004 if $year > 99
249 814 1190 if $year > 50