Branch Coverage

blib/lib/Math/Shape/Rectangle.pm
Criterion Covered Total %
branch 40 50 80.0


line true false branch
17 0 62 unless @_ == 5
27 0 12 unless $_[1]->isa('Math::Shape::Vector')
38 0 32 unless @_ == 2
44 8 24 if ($mod == 0) { }
8 16 elsif ($mod == 1) { }
8 8 elsif ($mod == 2) { }
8 0 elsif ($mod == 3) { }
82 0 8 unless $_[1]->isa('Math::Shape::LineSegment')
107 7 1 $axis_range->is_overlapping($r_projection) ? :
114 0 24 unless $_[1]->isa('Math::Shape::Vector')
140 14 56 if ($other_obj->isa('Math::Shape::Rectangle')) { }
12 44 elsif ($other_obj->isa('Math::Shape::Vector')) { }
24 20 elsif ($other_obj->isa('Math::Shape::Line')) { }
12 8 elsif ($other_obj->isa('Math::Shape::LineSegment')) { }
6 2 elsif ($other_obj->isa('Math::Shape::OrientedRectangle')) { }
2 0 elsif ($other_obj->isa('Math::Shape::Circle')) { }
152 12 2 if overlap($a_left, $a_right, $b_left, $b_right)
166 6 6 $left <= $other_obj->{'x'} && $bottom <= $other_obj->{'y'} && $other_obj->{'x'} <= $right && $other_obj->{'y'} <= $top ? :
187 12 12 $dp1 * $dp2 <= 0 || $dp2 * $dp3 <= 0 || $dp3 * $dp4 <= 0 ? :
198 6 6 unless $self->collides($s_line)
210 0 6 unless $s_range_x->is_overlapping($r_range_x)
222 0 6 unless $s_range_y->is_overlapping($r_range_y)
229 2 4 unless $self->collides($or_hull)
233 0 4 if $self->separating_axis($or_edge_0)
237 1 3 if $self->separating_axis($or_edge_1)