예제 #1
0
def test_str_returns_all_details():
    candle1 = Candle("Beach", 54, "lavender", "square", "4 hours",
                     "10cm by 10cm", "£100")
    result = candle1.__str__()
    assert result == "Candle name: Beach, ID: 54, fragrance: lavender, Candle type: square, Burn time: 4 hours, Dimensions: 10cm by 10cm, Price: £100"
예제 #2
0
def test_str_returns_all_details():
    candle1 = Candle("Vanilla",25,"fragrance","Tall","burn_time","Height","Width","$100")
    x = candle1.__str__()
    assert x == ("Candle name: Vanilla, ID = 25 fragrance:fragrance Candle time:seconds burn_time: burn_time_minutes, Height: height, Width: width, Price: $100")