|
|
@ -33,11 +33,15 @@ class MatchfieldPositioningTest { |
|
|
|
Coordinate[] coordinatesWithShip00_2_0 = new Coordinate[] { new Coordinate(0, 0), new Coordinate(1, 0) }; |
|
|
|
Coordinate[] coordinatesWithShip01_3_0 = new Coordinate[] { new Coordinate(0, 1), new Coordinate(1, 1), |
|
|
|
new Coordinate(2, 1) }; |
|
|
|
Coordinate[] coordinatesWithShip02_4_1 = new Coordinate[] { new Coordinate(0, 2), new Coordinate(0, 3), |
|
|
|
new Coordinate(0, 4), new Coordinate(0, 5) }; |
|
|
|
|
|
|
|
return Stream.of( |
|
|
|
Arguments.of("set ship from 0:0, length 2, direction 0", 10, new Coordinate(0, 0), 0, 2, |
|
|
|
coordinatesWithShip00_2_0), |
|
|
|
Arguments.of("set ship from 0:1, length 3, direction 0", 10, new Coordinate(0, 1), 0, 3, |
|
|
|
coordinatesWithShip01_3_0)); |
|
|
|
coordinatesWithShip01_3_0), |
|
|
|
Arguments.of("set ship from 0:2, length 4, direction 1", 10, new Coordinate(0, 2), 1, 4, |
|
|
|
coordinatesWithShip02_4_1)); |
|
|
|
} |
|
|
|
} |