Condition Coverage

blib/lib/DateTime.pm
Criterion Covered Total %
condition 123 142 86.6


and 3 conditions

line !l l&&!r l&&r condition
183 23415 25332 2 $p{'day'} > 28 and $p{'day'} > $class->_month_length($p{"year"}, $p{'month'})
273 25395 25 32137 defined $locale and ref $locale
321 232 40 33399 $offset >= 0 and $self->{'local_rd_secs'} >= $offset
40 204 28 $offset < 0 and $self->{'local_rd_secs'} >= 86400 + $offset
323 64 33291 44 $second < 60 and $offset > 0
33302 53 0 $second == 60 and $self->{'local_rd_secs'} == $offset && $offset > 0 || $offset == 0 && $self->{'local_rd_secs'} > 86399
349 0 2 5 $second == 60 and $self->{'local_rd_secs'} == 86400 + $offset
398 57 21 7545 $self->{'utc_rd_secs'} >= 0 and $self->{'utc_rd_secs'} <= 86399
489 56 0 3 @_ == 1 and not is_HashRef($_[0])
553 57599 0 10 $year >= 5000 and $tz
608 2 31250 693 $object->can("time_zone") and not $object->time_zone->is_floating
31252 687 6 $object->can("time_zone") and not $object->time_zone->is_floating and $rd_secs > 86399
31937 0 6 $object->can("time_zone") and not $object->time_zone->is_floating and $rd_secs > 86399 and $rd_secs <= $class->_day_length($rd_days)
740 1121 2 1 $p{'day_of_year'} == 366 and not $class->_is_leap_year($p{"year"})
1039 20 2 5 $week == 53 and $self->_weeks_in_year($year) == 52
1493 43 0 12 $dt1->time_zone->is_floating && $dt2->time_zone->is_floating
1500 38 0 5 $utc_rd_secs >= 86340 and not $is_floating
1527 36 8 11 $bigger->time_zone->has_dst_changes and $bigger->is_dst != $smaller->is_dst
1535 6 1 4 $bigger->is_dst and do {
1537 1 0 4 $prev_day && !$prev_day->is_dst
1546 5 5 1 not $bigger->is_dst and do {
1548 0 5 1 $prev_day && $prev_day->is_dst
1792 700 0 2 @_ == 1 and &blessed($_[0])
700 0 2 @_ == 1 and &blessed($_[0]) and $_[0]->isa($self->duration_class)
1876 425 113 2 not $dur->is_wrap_mode and $d > 28
1981 9002 3 4 not ref $dt2 and $dt2 == 9**9**9 || $dt2 == -9**9**9
1985 0 2 9001 DateTime::Helpers::can($dt1, "utc_rd_values") and DateTime::Helpers::can($dt2, "utc_rd_values")
1994 2 0 8999 not $consistent and DateTime::Helpers::can($dt1, "time_zone")
2 2 8997 not $consistent and DateTime::Helpers::can($dt1, "time_zone") and DateTime::Helpers::can($dt2, "time_zone")
2000 114 8881 2 $is_floating1 and not $is_floating2
111 8881 3 $is_floating2 and not $is_floating1
2024 3 1 1 $self->compare($lower) > 0 && $self->compare($upper) < 0

or 2 conditions

line l !l condition
266 4 1326 $ENV{'PERL_DATETIME_DEFAULT_TZ'} || 'floating'
602 7 31938 $rd_nanosecs ||= 0
2303 4 0 $VERSION || 'git'

or 3 conditions

line l !l&&r !l&&!r condition
248 1 2 46 $self->{'tz'}->is_floating or $self->{'utc_rd_secs'} - 86399 < $p{'second'} - 59
323 3 0 50 $self->{'local_rd_secs'} == $offset && $offset > 0 || $offset == 0 && $self->{'local_rd_secs'} > 86399
374 33299 79741 178 $self->{'tz'}->is_utc or $self->{'tz'}->is_floating
421 32771 24777 258 $self->{'tz'}->is_utc or $self->{'tz'}->is_floating
556 2 3 5 $tz_name eq "floating" or $tz_name eq "UTC"
1025 12 33 0 $self->{'utc_c'}{'week_year'} ||= $self->_week_values
1058 2 2 7 $dow == 4 || $dow == 3 && $self->_is_leap_year($year)
1898 23769 537 7628 $deltas{'days'} or $deltas{'months'}
1914 7574 3 24355 $deltas{'seconds'} or $deltas{'nanoseconds'}
1981 4 2 1 $dt2 == 9**9**9 || $dt2 == -9**9**9
2034 0 6 0 $class ||= ref $dt1
2194 9 16 145 $p{'to'} eq "week" or $p{'to'} eq "local_week"

xor 4 conditions

line l&&r l&&!r !l&&r !l&&!r condition
2269 0 31254 5 156 $self->{'tz'}->is_floating xor $was_floating