|
@ -125,7 +125,7 @@ class LogicTest { |
|
|
|
|
|
|
|
|
@Test |
|
|
@Test |
|
|
void setCurrentPlayerTest() { |
|
|
void setCurrentPlayerTest() { |
|
|
int player = 1; |
|
|
|
|
|
|
|
|
int player = 2; |
|
|
|
|
|
|
|
|
testObj.setCurrentPlayer(player); |
|
|
testObj.setCurrentPlayer(player); |
|
|
|
|
|
|
|
@ -142,6 +142,14 @@ class LogicTest { |
|
|
assertEquals(player, realResult); |
|
|
assertEquals(player, realResult); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Test |
|
|
|
|
|
void setPlayer1ScoreTest() { |
|
|
|
|
|
int expectedResult = 500; |
|
|
|
|
|
testObj.setPlayer1Score(expectedResult); |
|
|
|
|
|
|
|
|
|
|
|
assertEquals(expectedResult, testObj.player1Score); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
private static Stream<Arguments> playfieldResults() { |
|
|
private static Stream<Arguments> playfieldResults() { |
|
|
int[][] playfield1 = {{0, 0, 0, 0, 0, 0}, |
|
|
int[][] playfield1 = {{0, 0, 0, 0, 0, 0}, |
|
|
{0, 0, 0, 0, 0, 0}, |
|
|
{0, 0, 0, 0, 0, 0}, |
|
|