public void VehicleWestOrientedGoesForward_ButIsNotInTheLimit_ThenItCanMove() { //Arrange _direction = new WestDirection(); _vehicle = new Vehicle(_xPoint, _yPoint, _direction); _controlLogic = new ControlLogic(_vehicle, _permissiveLimits, _obstaclesEmptyList); //Act _controlLogic.ExecuteCommands(_commandList); //Assert Assert.AreNotEqual(_vehicle.X_Point, _xPoint); }
public void VehicleEastOrientedGoesForward_ButIsAlreadyInTheLimit_ThenCannotMove() { //Arrange _direction = new EastDirection(); _vehicle = new Vehicle(_xPoint, _yPoint, _direction); _controlLogic = new ControlLogic(_vehicle, _restrictiveLimits, _obstaclesEmptyList); //Act _controlLogic.ExecuteCommands(_commandList); //Assert Assert.AreEqual(_vehicle.X_Point, _xPoint); Assert.AreEqual(_vehicle.Y_Point, _yPoint); }
public void VehicleWestOrientedGoesForward_ButThereAreObstacles_ThenCannotMove() { //Arrange _direction = new WestDirection(); _vehicle = new Vehicle(_xPoint, _yPoint, _direction); _controlLogic = new ControlLogic(_vehicle, _permissiveLimits, _obstaclesWithItems); //Act _controlLogic.ExecuteCommands(_commandList); //Assert Assert.AreEqual(_vehicle.X_Point, _xPoint); Assert.AreEqual(_vehicle.Y_Point, _yPoint); }