|
@ -2,6 +2,7 @@ package de.hsfulda.onses; |
|
|
|
|
|
|
|
|
import de.hsfulda.onses.models.Card; |
|
|
import de.hsfulda.onses.models.Card; |
|
|
import de.hsfulda.onses.models.Game; |
|
|
import de.hsfulda.onses.models.Game; |
|
|
|
|
|
import de.hsfulda.onses.services.GameService; |
|
|
import org.junit.jupiter.api.DisplayName; |
|
|
import org.junit.jupiter.api.DisplayName; |
|
|
import org.junit.jupiter.api.Test; |
|
|
import org.junit.jupiter.api.Test; |
|
|
import static org.junit.jupiter.api.Assertions.*; |
|
|
import static org.junit.jupiter.api.Assertions.*; |
|
@ -46,6 +47,7 @@ public class GameTest { |
|
|
assertEquals(game.getDrawCardDeck().getFirst(), answer1); |
|
|
assertEquals(game.getDrawCardDeck().getFirst(), answer1); |
|
|
assertEquals(game.getDrawCardDeck().get(1), answer2); |
|
|
assertEquals(game.getDrawCardDeck().get(1), answer2); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@Test |
|
|
@Test |
|
|
@DisplayName("RelationshipGame_PlayerService") |
|
|
@DisplayName("RelationshipGame_PlayerService") |
|
|
public void RelationshipGame_PlayerService() { |
|
|
public void RelationshipGame_PlayerService() { |
|
@ -56,4 +58,14 @@ public class GameTest { |
|
|
// assert |
|
|
// assert |
|
|
assertEquals(expected, answer); |
|
|
assertEquals(expected, answer); |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Test |
|
|
|
|
|
@DisplayName("CheckForGetGameOver") |
|
|
|
|
|
public void CheckForGetGameOver() { |
|
|
|
|
|
GameService gameService = new GameService(); |
|
|
|
|
|
|
|
|
|
|
|
boolean gameOver = gameService.getGame().getGameOver(); |
|
|
|
|
|
|
|
|
|
|
|
assertFalse(gameOver); |
|
|
|
|
|
} |
|
|
|
|
|
} |