Branch Coverage

blib/lib/DateTime/Format/PGN.pm
Criterion Covered Total %
branch 42 62 67.7


line true false branch
23 3 0 unless not defined $_[0] or $_[0] == 0
31 4 0 unless not defined $_[0] or $_[0] == 0
50 17 25 if ($date =~ /^(\?{4}|[1-2]\d{3})\.(\?{2}|0[1-9]|1[0-2])\.(\?{2}|0[1-9]|[1-2]\d|3[0-1])$/) { }
57 24 1 if ($self->{'fix_errors'})
60 24 0 if ($date =~ /(\A|\D)([1-2]\d{3})(\D|\Z)/ and $2 > 0)
65 22 2 if ($date =~ /(\A|\D)(\d{1,2})\D+(\d{1,2})(\D|\Z)/) { }
1 1 elsif ($date =~ /(January|February|March|April|May|June|July|August|September|October|November|December)/) { }
66 16 6 if ($2 < 13 and $3 > 12 and $3 < 32 and $2 > 0 and $3 > 0 or $2 == $3 and $2 < 13 and $2 > 0) { }
2 4 elsif ($3 < 13 and $2 > 12 and $2 < 32 and $2 > 0 and $3 > 0) { }
77 0 1 if (index($1, 'January') > -1) { }
0 1 elsif (index($1, 'February') > -1) { }
0 1 elsif (index($1, 'March') > -1) { }
0 1 elsif (index($1, 'April') > -1) { }
0 1 elsif (index($1, 'May') > -1) { }
1 0 elsif (index($1, 'June') > -1) { }
0 0 elsif (index($1, 'July') > -1) { }
0 0 elsif (index($1, 'August') > -1) { }
0 0 elsif (index($1, 'September') > -1) { }
0 0 elsif (index($1, 'October') > -1) { }
0 0 elsif (index($1, 'November') > -1) { }
90 1 0 if $date =~ /(\A|\D)(\d{1,2})(\D|\Z)/ and $2 < 32 and $2 > 0
94 19 5 if (index($matches[1], '?') == -1 and index($matches[2], '?') == -1)
95 4 15 if ($matches[2] == 31 and $matches[1] == 4 || $matches[1] == 6 || $matches[1] == 9 || $matches[1] == 9 || $matches[1] == 11) { }
4 11 elsif ($matches[1] == 2) { }
100 1 3 if ($matches[2] == 29 and $matches[0] % 4 == 0 and $matches[0] % 100 > 0 or $matches[2] < 29) { }
112 25 17 if ($self->{'use_incomplete'}) { }
114 25 50 if index($_, '?') > -1
126 18 33 if index($_, '?') > -1
141 40 2 defined $dt->year ? :
142 30 12 defined $dt->month ? :
143 31 11 defined $dt->day ? :