public static void Setup(int testItems) { SetTestRepo(); for(int i=0;i<testItems;i++){ Product item=new Product(); _testRepo._items.Add(item); } }
public static void Setup(Product item) { SetTestRepo(); _testRepo._items.Add(item); }
public void PullingSingle_Should_Set_New_Product_IsNew_False() { var product = new Product(); product = Product.SingleOrDefault(x => x.ProductID == 1); Assert.Equal(false, product.IsNew()); }
public void PullingSingle_Should_Set_New_Product_IsLoaded_True() { var product = new Product(); product = Product.SingleOrDefault(x => x.ProductID == 1); Assert.Equal(true, product.IsLoaded()); }
public void CreatingNew_Product_Should_Set_IsLoaded_False() { var product = new Product(); Assert.Equal(false, product.IsLoaded()); }
public void CreatingNew_Product_Should_Set_IsNew_True() { var product = new Product(); Assert.Equal(true, product.IsNew()); }