Branch Coverage

blib/lib/Date/Extract/DE.pm
Criterion Covered Total %
branch 33 46 71.7


line true false branch
80 30 6 if $self->month_nr($month)
82 6 0 if $month and $month >= 1 and $month <= 12
91 2 26 if (defined $self->lookback_days and $result < $self->reference_date and $self->reference_date - $result > $self->lookback_days)
104 10 22 if (exists $date->{'conjugator'}) { }
105 6 4 unless $date->{'month2'}
106 6 4 if (not $date->{'year1'} || $date->{'year2'}) { }
2 2 elsif ($date->{'year1'} and not $date->{'year2'}) { }
0 2 elsif (not $date->{'year1'} and $date->{'year2'}) { }
118 0 6 if (1 == 'DateTime'->compare_ignore_floating($dti1, $dti2)) { }
136 0 2 if (1 == 'DateTime'->compare_ignore_floating($dti1, $dti2)) { }
154 0 0 if (1 == 'DateTime'->compare_ignore_floating($dti1, $dti2)) { }
163 8 2 if ($date->{'conjugator'} eq 'range') { }
2 0 elsif ($date->{'conjugator'} eq 'enum') { }
193 22 0 if (not $date->{'year1'}) { }
275 10 86 if (exists $date->{$c})
276 4 6 if ($c eq 'and') { }
277 2 2 if (exists $date->{'between'}) { }
289 32 0 if $date->{'day1'}
290 10 22 if $date->{'day2'}
292 32 0 if $date->{'month1'}
294 4 28 if $date->{'month2'}
297 0 32 unless (eval { do { foreach my $c ('enum', 'range', 'and') { if (exists $date->{$c}) { if ($c eq 'and') { if (exists $date->{'between'}) { $date->{'conjugator'} = 'range'; } else { $date->{'conjugator'} = 'enum'; } ; } else { $date->{'conjugator'} = $c; } ; } ; } ; $date->{'day1'} = int $date->{'day1'} if $date->{'day1'}; $date->{'day2'} = int $date->{'day2'} if $date->{'day2'}; $date->{'month1'} = $self->_translate_month($date->{'month1'}) if $date->{'month1'}; $date->{'month2'} = $self->_translate_month($date->{'month2'}) if $date->{'month2'}; push @found_dates, $date; 1 } })
298 0 0 if $@