示例#1
0
 def test_max_value_should_reject_comparison_with_wads(self):
     with pytest.raises(ArithmeticError):
         Ray.max(Ray(10), Wad(20))
     with pytest.raises(ArithmeticError):
         Ray.max(Ray(25), Wad(15))
示例#2
0
 def test_max_value_should_reject_comparison_with_ints(self):
     with pytest.raises(ArithmeticError):
         Ray.max(Ray(10), 20)
     with pytest.raises(ArithmeticError):
         Ray.max(15, Ray(25))
示例#3
0
 def test_max_value(self):
     assert Ray.max(Ray(10), Ray(20)) == Ray(20)
     assert Ray.max(Ray(25), Ray(15)) == Ray(25)
     assert Ray.max(Ray(25), Ray(15), Ray(40)) == Ray(40)