public async Task Ensure_Method_Invocations_For_GetAllCommandAsync() { var service = new ServiceBaseMock(new PersonProxyStub()); await service.GetAllCommand().ExecuteAsync(); service.OnGetAllCommandInitializationAsyncWasInvoked.ShouldBe(true); service.GetValidationResultsForGetAllWasInvoked.ShouldBe(true); service.GetBusinessRulesForGetAllAsyncWasInvoked.ShouldBe(true); service.GetAllErrorsForGetAllAsyncWasInvoked.ShouldBe(true); service.GetAllAsyncWasInvoked.ShouldBe(true); }
public void Ensure_Method_Invocations_For_GetAllCommand() { var service = new ServiceBaseMock(new PersonProxyStub()); var result = service.GetAllCommand().Execute(); service.OnGetAllCommandInitializationWasInvoked.ShouldBe(true); service.GetValidationResultsForGetAllWasInvoked.ShouldBe(true); service.GetBusinessRulesForGetAllWasInvoked.ShouldBe(true); service.GetAllErrorsForGetAllWasInvoked.ShouldBe(true); service.GetAllWasInvoked.ShouldBe(true); }