public async Task <MemoModel> GetCreatedSalesInvoiceData() { var model = GetMemoModelToCreate_SalesInvoice(); await _service.CreateAsync(model); return(await _service.ReadBySalesInvoiceAsync(model.SalesInvoiceNo)); }
public async Task Should_Success_MapToViewModel_SalesInvoice() { var dbContext = GetDbContext(GetCurrentMethod()); var serviceProviderMock = GetServiceProviderMock(); var service = new MemoService(dbContext, serviceProviderMock.Object); var dataUtil = new MemoDataUtil(service); var data = await dataUtil.GetCreatedSalesInvoiceData(); var result = await service.ReadBySalesInvoiceAsync(data.SalesInvoiceNo); Assert.NotNull(result); }