diff --git a/src/test/java/inf112/fiasko/roborally/objects/PhaseTest.java b/src/test/java/inf112/fiasko/roborally/objects/PhaseTest.java index 9b2bd43..36d8642 100644 --- a/src/test/java/inf112/fiasko/roborally/objects/PhaseTest.java +++ b/src/test/java/inf112/fiasko/roborally/objects/PhaseTest.java @@ -461,4 +461,17 @@ public class PhaseTest { assertFalse(board.isRobotAlive(RobotID.ROBOT_1)); assertNull(board.getRobotOnPosition(new Position(7, 0))); } + + @Test + public void robotOnConveyorBeltFacingOutOfMapMovesIntoWallIsBlocked() throws IOException, InterruptedException { + List robots = new ArrayList<>(); + List players = new ArrayList<>(); + robots.add(new Robot(RobotID.ROBOT_1, new Position(0, 0))); + players.add(new Player(RobotID.ROBOT_1, "Player 1")); + + Phase testPhase = createPhaseAndLoadBoard(players, robots); + testPhase.moveAllConveyorBelts(); + + assertNull(board.getRobotOnPosition(new Position(0, 0))); + } }