Branch Coverage

blib/lib/Date/Easy/Datetime.pm
Criterion Covered Total %
branch 69 80 86.2


line true false branch
30 4 35 exists $ZONE_FLAG{$_} ? :
42 396 2413 @_ % 2 == 0 ? :
44 7 2802 if ($datetime =~ /^-?\d+$/) { }
51 318 2484 unless defined $t
52 1 2801 unless defined $t
103 2549 498 $zonespec eq 'local' ? :
106 337 2710 if $num_defined == 0
107 12 2698 if ($num_defined < 3)
111 0 12 unless defined $month
112 0 12 unless defined $day
113 12 0 $month > $lt[4] ? :
12 0 unless defined $year
117 1780 930 if $year < 1000
119 8 2637 unless $month >= 0 and $month <= 11 and $day >= 1 and $day <= 31 and $hour <= 23 and $min <= 59 and $sec <= 59
135 318 2484 unless defined $year
152 563 1921 if (defined $zone) { }
155 0 563 unless defined $result
161 0 1921 unless defined $result
171 107 211 $zonespec eq 'local' ? :
182 4956 3273 @_ == 2 || @_ == 7 ? :
183 1 8228 unless exists $ZONE_FLAG{$zonespec}
186 9 8219 if (@_ == 0) { }
44 8175 elsif (@_ == 6) { }
8170 5 elsif (@_ == 1) { }
195 12 32 $zonespec eq 'local' ? :
199 1 43 unless defined $t
204 3214 4956 if (my $conv_class = &blessed($t))
206 3212 2 if ($t->isa('Time::Piece')) { }
236 3 3 if ($conv_spec =~ /^(\W)(\w+)$/)
241 2 1 if ($conv_spec eq 'Time::Piece') { }
262 2 12 unless +(shift())->{'impl'}->day_of_week
287 4909 9897 unless &blessed($operand)
288 9897 0 if $operand->isa('Date::Easy::Datetime')
289 0 0 if $operand->isa('Time::Piece')
307 17 2316 if (&blessed($_[1]) and $_[1]->isa('Date::Easy::Units')) { }
320 16 886 if (&blessed($_[1]) and $_[1]->isa('Date::Easy::Units')) { }
33 853 elsif (&blessed($_[1]) and $_[1]->isa('Date::Easy::Datetime')) { }
323 0 16 if $_[2]
329 0 33 $_[2] ? :
330 30 3 $lhs->isa('Date::Easy::Date') && $rhs->isa('Date::Easy::Date') ? :