예제 #1
0
 def test_div_exception(num1, num2, expection,self):
     assert div(num1, num2) == expection
예제 #2
0
 def test_div_string(num1, num2, expection,self):
     assert div(num1, num2) == expection
예제 #3
0
def test_div_int(num1, num2, expection):
    assert div(num1, num2) == expection
예제 #4
0
 def test_div_float(num1, num2, expection,self):
     assert div(num1, num2) == expection
예제 #5
0
def test_div_exception(num1, num2, expection):
    with pytest.raises(ZeroDivisionError):
        assert div(num1, num2) == expection