diff --git a/game-app/game-core/src/test/java/games/strategy/engine/data/MapTest.java b/game-app/game-core/src/test/java/games/strategy/engine/data/MapTest.java index 79613207da8..5b3c6b6580a 100644 --- a/game-app/game-core/src/test/java/games/strategy/engine/data/MapTest.java +++ b/game-app/game-core/src/test/java/games/strategy/engine/data/MapTest.java @@ -5,6 +5,7 @@ import static org.junit.jupiter.api.Assertions.assertNotNull; import static org.junit.jupiter.api.Assertions.assertNull; import static org.junit.jupiter.api.Assertions.assertTrue; +import static org.mockito.Mockito.when; import java.util.Set; import org.junit.jupiter.api.BeforeEach; @@ -98,6 +99,7 @@ void setUp() { map.addConnection(bd, cd); map.addConnection(cd, dd); nowhere = new Territory("nowhere", false, gameData); + when(gameData.getMap()).thenReturn(map); } @Test