public void DeleteOffersWithoutProductTests() { // Arrange var offerService = new OfferService(); var offers = new List <Offer>(); offers.Add(new Offer() { ProductIeId = 1 }); offers.Add(new Offer() { ProductIeId = 2 }); offers.Add(new Offer() { ProductIeId = 3 }); offers.Add(new Offer() { ProductIeId = 4 }); var ids = new List <Product>() { new Product() { ProductExId = 1, ProductIeId = 11 }, new Product() { ProductExId = 2, ProductIeId = 12 } }; // Act offerService.DeleteOffersWithoutProduct(offers, ids); // Assert Assert.AreEqual(offers.Count, 2); }