Branch Coverage

blib/lib/DateTimeX/Easy.pm
Criterion Covered Total %
branch 61 82 74.3


line true false branch
419 44 17 if $_[0] and $_[0] eq "DateTimeX::Easy"
422 55 6 if @_ % 2
425 6 55 if exists $in{'parse'}
430 1 60 if exists $in{'time_zone_if_floating'}
434 2 59 if exists $in{'ambiguous'}
437 0 61 if exists $in{'tz'}
438 6 55 if exists $in{'timezone'}
441 7 54 if exists $in{'time_zone'}
447 61 0 if ($parse)
448 6 55 if (&blessed($parse) and $parse->isa('DateTime')) { }
464 0 8 if $last_delta
467 6 2 if ($first_or_last ne 'first') { }
477 0 55 if ($parse =~ s/^\s*(start|this|next|first|last|(?:begin|end)(?:ning)?)\s+(year|month|day|hour|minute|second)(?:\s+of\s+)?//) { }
4 51 elsif ($parse =~ s/^\s*(year|month|day|hour|minute|second)\s+of\s+//i) { }
4 47 elsif (@delta) { }
483 0 0 if $last_delta and $last_delta->{'last'}
485 0 0 unless $parse
492 3 1 if $last_delta and $last_delta->{'last'}
501 4 0 if ($delta_range)
503 3 1 if ($last_delta->{'last'})
510 1 54 if $got_ambiguous and not $ambiguous
515 0 0 ref $parser_order eq 'ARRAY' ? :
0 54 $parser_order ? :
523 0 0 ref $parser_exclude eq 'ARRAY' ? :
0 54 if $parser_exclude
535 3 51 if ($parse =~ /^[1-9]\d{3}$/)
541 0 116 if $parser_exclude{$parser}
557 60 56 if $@
560 0 60 unless $parse_dt
565 60 0 if ($parse_dt)
571 0 60 unless my $dt = "DateTime"->new(%DateTime)
573 13 47 if ($time_zone) { }
1 92 elsif ($time_zone_if_floating and $dt->time_zone->is_floating) { }
574 1 12 if ($soft_time_zone_conversion)
583 1 59 if ($truncate) { }
7 52 elsif (@delta) { }
584 0 1 if ref $truncate eq "ARRAY"
585 0 1 if ref $truncate eq "HASH"
595 7 7 if ($delta->{'truncate'}) { }
599 5 2 if $delta->{'add'}
600 5 2 if $delta->{'subtract'}