def test_max_value_should_reject_comparison_with_ints(self): with pytest.raises(ArithmeticError): Rad.max(Rad(10), 20) with pytest.raises(ArithmeticError): Rad.max(15, Rad(25))
def test_max_value(self): assert Rad.max(Rad(10), Rad(20)) == Rad(20) assert Rad.max(Rad(25), Rad(15)) == Rad(25) assert Rad.max(Rad(25), Rad(15), Rad(40)) == Rad(40)