def test_first():
    assert reciprocal(1) == 1
Beispiel #2
0
def test_reciprocal_0():
    assert reciprocal(0) == "error"
Beispiel #3
0
def test_reciprocal_minus_2():
    assert reciprocal(-2) == -0.5
Beispiel #4
0
def test_reciprocal_1():
    assert reciprocal(1) == 1
def test_reciprocal(x, y):
    assert reciprocal(x) == y