Exemplo n.º 1
0
 public void GetByIdAsync_ItShouldCallTheCustomerService()
 {
     ArrangeAndAct();
     StubCustomerService.AssertWasCalled(s => s.GetByIdAsync(Arg <int> .Is.Anything));
 }
 public void CreateAsync_ItShouldCallTheCustomerService()
 {
     ArrangeAndAct();
     //StubCustomerService.AssertWasCalled(s => s.AddAsync(NewCustomer));
     StubCustomerService.AssertWasCalled(s => s.AddCustomerAsync(NewCustomer));
 }
 public void DeleteByIdAsync_ItShouldCallTheCustomerService_DeleteMethod()
 {
     ArrangeAndAct();
     //StubCustomerService.AssertWasCalled(s => s.DeleteAsync(Arg<Customer>.Is.Anything));
     StubCustomerService.AssertWasCalled(s => s.Delete(Arg <Customer> .Is.Anything));
 }
Exemplo n.º 4
0
 public void DeleteByIdAsyncNotFound_ItShouldCallTheCustomerService_GetByIdMethod()
 {
     ArrangeAndAct();
     StubCustomerService.AssertWasCalled(s => s.GetByIdAsync(Arg <int> .Is.Anything));
 }
 public void GetAllAsync_ItShouldCallTheCustomerService()
 {
     ArrangeAndAct();
     StubCustomerService.AssertWasCalled(s => s.GetAllAsync());
 }