public void Should_Throw_If_Has_A_Non_Zero_Exit_Code() { // Given var fixture = new AppleSimulatorListPairsFixture(); fixture.GivenProcessExitsWithCode(1); // When fixture.Invoking(x => x.Run()) // Then .ShouldThrow <CakeException>() .WithMessage("AppleSimulator: Process returned an error (exit code 1)."); }
public void Should_Throw_If_Process_Was_Not_Started() { // Given var fixture = new AppleSimulatorListPairsFixture(); fixture.GivenProcessCannotStart(); // When fixture.Invoking(x => x.Run()) // Then .ShouldThrow <CakeException>() .WithMessage("AppleSimulator: Process was not started."); }
public void Should_Throw_If_AppleSimulator_Was_Not_Found() { // Given var fixture = new AppleSimulatorListPairsFixture(); fixture.GivenDefaultToolDoNotExist(); // When fixture.Invoking(x => x.Run()) // Then .ShouldThrow <CakeException>() .WithMessage("AppleSimulator: Could not locate executable."); }