示例#1
0
def test_i():
    assert div(2, 2) == 1
示例#2
0
def test_div_stringparam(num1, num2, expection):
    assert div(num1, num2) == expection
示例#3
0
def test_div_zeroparam(num1, num2, expection):
    with pytest.raises(eval(expection)):
        div(num1, num2)
示例#4
0
def test_div_floatparam(num1, num2, expection):
    assert div(num1, num2) == expection