Branch Coverage

blib/lib/Game/Battleship/Grid.pm
Criterion Covered Total %
branch 16 48 33.3


line true false branch
36 0 15 if (defined $craft->position) { }
62 15 4 if ($x1 <= $self->dimension->[0] and $y1 <= $self->dimension->[1])
71 60 15 if ($craft->name ne $_->name)
73 0 60 if (defined $_->position and _segment_intersection($x0, $y0, $x1, $y1, @{$_->position->[0];}, @{$_->position->[1];}))
87 15 0 unless $collide
98 32 19 if ($orient) { }
118 11 8 if ($orient) { }
138 0 30 unless @_ == 8
156 16 14 if ($delta != 0) { }
161 0 16 $u <= 1 && $u >= 0 && $v <= 1 && $v >= 0 ? :
165 14 0 if $t1 != 0 and $t2 != 0
173 0 0 if ($x0 != $x1) { }
175 0 0 $x0 < $x1 ? :
176 0 0 $x0 > $x1 ? :
177 0 0 $x2 < $x3 ? :
178 0 0 $x2 > $x3 ? :
180 0 0 if ($d < $a or $c > $b) { }
0 0 elsif ($d == $a or $c == $b) { }
194 0 0 $y0 < $y1 ? :
195 0 0 $y0 > $y1 ? :
196 0 0 $y2 < $y3 ? :
197 0 0 $y2 > $y3 ? :
199 0 0 if ($d < $a or $c > $b) { }
0 0 elsif ($d == $a or $c == $b) { }