From bc04d21afb9534e3f0aed53045ecc3a30a37bf81 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Tue, 31 May 2011 18:25:47 +0200 Subject: View: Refactor bottom panel display git-svn-id: svn://sunsvr01.isp.uni-luebeck.de/swproj13/trunk@354 72836036-5685-4462-b002-a69064685172 --- test/jrummikub/control/GameControlTest.java | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'test/jrummikub/control/GameControlTest.java') diff --git a/test/jrummikub/control/GameControlTest.java b/test/jrummikub/control/GameControlTest.java index 706928c..db60b05 100644 --- a/test/jrummikub/control/GameControlTest.java +++ b/test/jrummikub/control/GameControlTest.java @@ -1,8 +1,7 @@ package jrummikub.control; -import static jrummikub.model.StoneColor.RED; -import static org.junit.Assert.assertSame; -import static org.junit.Assert.assertTrue; +import static jrummikub.model.StoneColor.*; +import static org.junit.Assert.*; import java.awt.Color; @@ -12,6 +11,7 @@ import jrummikub.model.PlayerSettings; import jrummikub.model.Position; import jrummikub.model.Stone; import jrummikub.util.Pair; +import jrummikub.view.IView.BottomPanelType; import jrummikub.view.MockView; import org.junit.Before; @@ -41,7 +41,7 @@ public class GameControlTest { @Test public void testStartFirstRound() { gameControl.startGame(); - assertTrue(view.displayStartTurnPanel); + assertSame(BottomPanelType.START_TURN_PANEL, view.bottomPanelType); } /** */ @@ -75,10 +75,10 @@ public class GameControlTest { view.tablePanel.clickEvent.emit(new Position(0, 0)); view.playerPanel.endTurnEvent.emit(); - assertTrue(view.displayWinPanel); + assertSame(BottomPanelType.WIN_PANEL, view.bottomPanelType); view.newRoundEvent.emit(); - assertTrue(view.displayStartTurnPanel); + assertSame(BottomPanelType.START_TURN_PANEL, view.bottomPanelType); } /** */ @@ -91,7 +91,7 @@ public class GameControlTest { view.playerPanel.endTurnEvent.emit(); view.startTurnEvent.emit(); view.playerPanel.redealEvent.emit(); - assertTrue(view.displayStartTurnPanel); + assertSame(BottomPanelType.START_TURN_PANEL, view.bottomPanelType); view.startTurnEvent.emit(); assertSame(firstPlayer, gameControl.roundControl.roundState .getActivePlayer().getPlayerSettings()); -- cgit v1.2.3