public async Task DeleteDAppOfferById() { //Arrange var product1 = new DAppOffer { Id = Guid.NewGuid(), Title = "Title1", Description = "Description1" }; var product2 = new DAppOffer { Id = Guid.NewGuid(), Title = "Title2", Description = "Description2" }; await _dAppRepository.CreateDAppOffer(product1); await _dAppRepository.CreateDAppOffer(product2); //Act await _dAppRepository.DeleteDAppOffer(product1.Id); var result = await _dAppRepository.GetDAppOffer(product1.Id); var resultAll = await _dAppRepository.GetAllDAppOffers(); //Assert Assert.Null(result); Assert.NotNull(resultAll); Assert.NotEmpty(resultAll); Assert.Single(resultAll); }
public async Task <PagedList <DAppOffer> > GetOffers(GetDAppOfferModel getDAppOfferModel) { return(await _dAppRepository.GetAllDAppOffers(getDAppOfferModel)); }