public void IfStockIsTrackedAVariantWithZeroRemainingStockShouldNotBeInStock() { ProductVariant productVariant = new ProductVariantBuilder().Build(); ProductStockChecker productStockChecker = new ProductStockCheckerBuilder().StockRemaining(0).Build(); productStockChecker.IsInStock(productVariant).Should().BeFalse(); }
public void IfStockIsTrackedAVariantWithSomeStockRemainingStockShouldBeInStock() { ProductVariant productVariant = new ProductVariantBuilder().StockRemaining(1).Build(); ProductStockChecker productStockChecker = new ProductStockCheckerBuilder().StockRemaining(1).Build(); productStockChecker.IsInStock(productVariant).Should().BeTrue(); }
public void UntrackedVariantsAreAlwaysInStock() { ProductVariant productVariant = new ProductVariantBuilder().DoNotTrackStock().Build(); ProductStockChecker productStockChecker = new ProductStockCheckerBuilder().Build(); productStockChecker.IsInStock(productVariant).Should().BeTrue(); }