internal void ItCanDeleteAService(bool autoStartArgument, ServiceStartType createdServiceStartType) { // Given GivenTheServiceControlManagerCanBeOpened(); var service = GivenTheTestServiceExists(); GivenTheServiceCanBeDeleted(service); // When sut.DeleteService(TestServiceName); // Then A.CallTo(() => service.Delete()).MustHaveHappened(); }
public void ItShallThrowOnDeleteServiceWithEmptyServiceName() { Action invocation = () => sut.DeleteService(serviceName: string.Empty); invocation.ShouldThrow <ArgumentException>().Which.ParamName.Should().Be("serviceName"); }