private void NaNQuantity() { // Arrange Ingredient ingredient = new Ingredient(double.NaN, 100); // Act bool isValid = Calculator.IsQuantityValid(ingredient); // Assert Assert.False(isValid, "Validation error!"); }
public void NaNUnknownQuantity() { // Arrange Ingredient ingredient = new Ingredient(double.NaN, 100, true); // Act bool isValid = Calculator.IsQuantityValid(ingredient); // Assert Assert.True(isValid, "Validation error!"); }
public void ZeroQuantity() { // Arrange Ingredient ingredient = new Ingredient(0, 100); // Act bool isValid = Calculator.IsQuantityValid(ingredient); // Assert Assert.False(isValid, "Validation error!"); }