Branch Coverage

blib/lib/TimeZone/Solar.pm
Criterion Covered Total %
branch 80 86 93.0


line true false branch
74 1 25331 unless (exists $constants{$name})
109 0 2328 exists $opts{'test_break_eval'} && $opts{'test_break_eval'} ? :
127 0 2328 unless ($class_check)
177 1 456 ref $class ? :
178 2 455 unless (defined $classname)
181 3 452 unless ($class->isa("TimeZone::Solar"))
194 56 4495 if ($type eq "DateTime::TimeZone")
210 1 0 if (defined ${$class . "::VERSION";})
223 1 114 unless ($param_ref->{'latitude'} =~ /^[-+]?\d+(\.\d+)?$/x)
226 2 112 if (abs $param_ref->{'latitude'} > _const("MAX_LATITUDE_FP") + _const("PRECISION_FP"))
231 56 56 if (abs $param_ref->{'latitude'} >= _const("LIMIT_LATITUDE") - _const("PRECISION_FP"))
233 28 28 $use_lon_tz ? :
246 281 222 $sign > 0 ? :
1156 503 $use_lon_tz ? :
252 593 563 $sign > 0 ? :
1156 503 $use_lon_tz ? :
259 1 1721 unless (exists $params{'longitude'})
264 115 1606 if (exists $params{'latitude'})
270 56 56 if ref $lat_params eq "HASH"
279 1 1661 unless ($params{'longitude'} =~ /^[-+]?\d+(\.\d+)?$/x)
282 2 1659 if (abs $params{'longitude'} > _const("MAX_LONGITUDE_FP") + _const("PRECISION_FP"))
289 1156 503 $use_lon_tz ? :
290 1156 503 $use_lon_tz ? :
293 45 1614 if ($params{'longitude'} >= _const("MAX_LONGITUDE_INT") - $tz_degree_width / 2 - _const("PRECISION_FP") or $params{'longitude'} <= -_const("MAX_LONGITUDE_INT") + _const("PRECISION_FP"))
308 14 1600 if ($params{'longitude'} <= -_const("MAX_LONGITUDE_INT") + $tz_degree_width / 2 + _const("PRECISION_FP"))
322 829 771 $params{'longitude'} > -$tz_degree_width / 2 + _const('PRECISION_FP') ? :
341 1 1718 unless (defined $hashref)
344 1 1717 if (ref $hashref ne "HASH")
347 1 1716 unless (exists $hashref->{'short_name'})
350 1 1715 unless ($hashref->{'short_name'} =~ _const("TZSOLAR_ZONE_RE"))
359 905 810 if (exists $_INSTANCES{$class})
363 1016 794 if (exists $hashref->{$key}) { }
374 0 810 unless ($class->isa("TimeZone::Solar"))
393 1 1722 unless ($class->isa("TimeZone::Solar"))
400 839 883 if ($in_class =~ qr/ $tzsolar_class_prefix ( $tzsolar_zone_re )/x)
402 44 795 if (substr($in_tz, 0, 4) eq 'East') { }
42 753 elsif (substr($in_tz, 0, 4) eq 'West') { }
753 0 elsif (substr($in_tz, 0, 3) eq 'Lon') { }
412 376 377 substr($in_tz, 6, 1) eq 'E' ? :
443 0 112 unless exists $self->{'latitude'}
486 930 785 $offset_min >= 0 ? :
515 1 47 $self->{'offset_min'} == 0 ? :
543 388 8 if (ref $arg and $arg->isa("TimeZone::Solar"))