public void TooBig_CreateProductsTest() { var store = new StaticProductStore(); var products = store.GetProductsByIds(new[] { 200 }); Assert.IsFalse(products.Any()); }
public void Several_CreateProductsTest() { var store = new StaticProductStore(); var products = store.GetProductsByIds(new[] { 2, 6, 9 }).ToArray(); Assert.AreEqual(3, products.Length); Assert.AreEqual("2", products[0].ProductId); Assert.AreEqual("6", products[1].ProductId); Assert.AreEqual("9", products[2].ProductId); }
public void Single_CreateProductTest() { var store = new StaticProductStore(); var product = store.GetProductsByIds(new[] { 0 }).Single(); Assert.AreEqual("0", product.ProductId); Assert.IsNotNull(product.ProductName); Assert.IsNotNull(product.ProductDescription); Assert.IsNotNull(product.Price); }