From 7114b43f39a323737640cb196da0d9347d76e880 Mon Sep 17 00:00:00 2001 From: joffrey-bion Date: Sat, 13 Feb 2021 17:16:19 +0100 Subject: Avoid exception in test (harmless, but still) --- .../test/kotlin/org/luxons/sevenwonders/server/SevenWondersTest.kt | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'sw-server/src/test/kotlin/org/luxons') diff --git a/sw-server/src/test/kotlin/org/luxons/sevenwonders/server/SevenWondersTest.kt b/sw-server/src/test/kotlin/org/luxons/sevenwonders/server/SevenWondersTest.kt index 4d76d7b8..df40b93d 100644 --- a/sw-server/src/test/kotlin/org/luxons/sevenwonders/server/SevenWondersTest.kt +++ b/sw-server/src/test/kotlin/org/luxons/sevenwonders/server/SevenWondersTest.kt @@ -6,10 +6,7 @@ import kotlinx.coroutines.launch import kotlinx.coroutines.withTimeout import kotlinx.coroutines.withTimeoutOrNull import org.junit.runner.RunWith -import org.luxons.sevenwonders.client.SevenWondersClient -import org.luxons.sevenwonders.client.SevenWondersSession -import org.luxons.sevenwonders.client.createGameAndAwaitLobby -import org.luxons.sevenwonders.client.joinGameAndAwaitLobby +import org.luxons.sevenwonders.client.* import org.luxons.sevenwonders.model.Action import org.luxons.sevenwonders.model.api.GameListEvent import org.luxons.sevenwonders.model.api.LobbyDTO @@ -66,7 +63,7 @@ class SevenWondersTest { val outsiderSession = newPlayer("Outsider") val gameStartedEvents = outsiderSession.watchGameStarted() - ownerSession.startGame() + ownerSession.startGameAndAwaitFirstTurn() val nullForTimeout = withTimeoutOrNull(50) { gameStartedEvents.first() } assertNull(nullForTimeout, "outsider should not receive the game start event of this game") -- cgit