def test_set_price(self): test_coffee = Coffee( CoffeeIngredients(water_in_ml=100, milk_in_ml=150, coffee_beans_in_gramm=15), 5) test_coffee.set_price(1) self.assertEqual(test_coffee.get_price(), 1)
def test_set_price_negative(self): test_coffee = Coffee( CoffeeIngredients(water_in_ml=100, milk_in_ml=150, coffee_beans_in_gramm=15), 5) #with self.assertRaises(ValueError): with self.assertRaises(SyntaxError): test_coffee.set_price(-1)