コード例 #1
0
def test_calculate_total_price_basket1_subtotal():
    result = calculate_total_price(basket1)["subtotal"]
    assert result == 17.48
コード例 #2
0
def test_calculate_total_price_basket2_tax():
    result = calculate_total_price(basket2)["tax"]
    assert result == 1.3965
コード例 #3
0
def test_calculate_total_price_basket2_total():
    result = calculate_total_price(basket2)["total"]
    assert result == 17.3565
コード例 #4
0
def test_calculate_total_price_basket2_subtotal():
    result = calculate_total_price(basket2)["subtotal"]
    assert result == 15.96
コード例 #5
0
def test_calculate_total_price_basket1_total():
    result = calculate_total_price(basket1)["total"]
    assert result == 19.009500000000003
コード例 #6
0
def test_calculate_total_price_basket1_tax():
    result = calculate_total_price(basket1)["tax"]
    assert result == 1.5294999999999999
コード例 #7
0
def test_calculate_total_price():
    assert calculate_total_price(4) == 4.24
コード例 #8
0
def test_calculate_total_price():
    # it should return the sum of two numbers
    assert calculate_total_price(3.21, 10) == 13.21