public void WhenParameterCountIs3_And_ParametersAreValid__ResponseShouldNotBeNull(string arg, int expectedX, int expectedY, CompassDirections expectedDirection) { var sut = new RoverBuilder(); Vehicle vehicle = sut.Build(arg); Assert.NotNull(vehicle); Assert.Equal(expectedX, vehicle.CurrentPoint.X); Assert.Equal(expectedY, vehicle.CurrentPoint.Y); Assert.Equal(expectedDirection, vehicle.Facade); }
public void WhenParameterIsNotValid__VehicleBuilderParameterNotValidExceptionOccurs(string arg) { var sut = new RoverBuilder(); Assert.Throws <VehicleBuilderParameterNotValidException>(() => sut.Build(arg)); }
public void WhenParameterIsNull__VehicleBuilderParameterNotValidExceptionOccurs() { var sut = new RoverBuilder(); Assert.Throws <VehicleBuilderParameterNotValidException>(() => sut.Build(null)); }