diff options
Diffstat (limited to 'test/jrummikub/control')
-rw-r--r-- | test/jrummikub/control/turn/TurnControlTest.java | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/test/jrummikub/control/turn/TurnControlTest.java b/test/jrummikub/control/turn/TurnControlTest.java index 9140323..11c4c2b 100644 --- a/test/jrummikub/control/turn/TurnControlTest.java +++ b/test/jrummikub/control/turn/TurnControlTest.java @@ -21,6 +21,7 @@ import jrummikub.control.turn.HumanTurnControl; import jrummikub.model.IHand; import jrummikub.model.ITable; import jrummikub.model.MockHand; +import jrummikub.model.MockPlayer; import jrummikub.model.MockTable; import jrummikub.model.Position; import jrummikub.model.Stone; @@ -68,6 +69,7 @@ public class TurnControlTest { } HumanTurnControl testControl; + MockPlayer mockPlayer; MockView mockView; MockTimer mockTimer; MockTable mockTable; @@ -105,8 +107,10 @@ public class TurnControlTest { mockTimer = new MockTimer(); mockTable = new MockTable(); mockHand = new MockHand(); + mockPlayer = new MockPlayer(null, null); + mockPlayer.hand = mockHand; testControl = new HumanTurnControl(mockTimer); - testControl.setup(mockHand, mockTable, mockView, false, false); + testControl.setup(mockPlayer, mockTable, mockView, false, false); } /** */ @@ -131,7 +135,7 @@ public class TurnControlTest { mockHand.iterable = stones; testControl = new HumanTurnControl(mockTimer); - testControl.setup(mockHand, mockTable, mockView, false, false); + testControl.setup(mockPlayer, mockTable, mockView, false, false); testControl.startTurn(); int i = 0; @@ -627,7 +631,7 @@ public class TurnControlTest { public void testAddLeft() { AccessibleTable table = new AccessibleTable(); HumanTurnControl turnControl = new HumanTurnControl(mockTimer); - turnControl.setup(mockHand, table, mockView, false, false); + turnControl.setup(mockPlayer, table, mockView, false, false); turnControl.startTurn(); Stone blueOne = new Stone(1, BLUE); Stone redOne = new Stone(1, RED); @@ -744,7 +748,7 @@ public class TurnControlTest { public void testAddRight() { AccessibleTable table = new AccessibleTable(); HumanTurnControl turnControl = new HumanTurnControl(mockTimer); - turnControl.setup(mockHand, table, mockView, false, false); + turnControl.setup(mockPlayer, table, mockView, false, false); turnControl.startTurn(); Stone blueOne = new Stone(1, BLUE); Stone redOne = new Stone(1, RED); @@ -861,7 +865,7 @@ public class TurnControlTest { public void testAddNewSet() { AccessibleTable table = new AccessibleTable(); HumanTurnControl turnControl = new HumanTurnControl(mockTimer); - turnControl.setup(mockHand, table, mockView, false, false); + turnControl.setup(mockPlayer, table, mockView, false, false); turnControl.startTurn(); Stone blueOne = new Stone(1, BLUE); Stone redOne = new Stone(1, RED); |