def test_bounded_cone_bounding_box(self): shape = Cone() shape.minimum = -5 shape.maximum = 3 box = shape.bounds_of() self.assertEqual(box.min, Point(-5, -5, -5)) self.assertEqual(box.max, Point(5, 3, 5))
def test_unbounded_cone_bounding_box(self): shape = Cone() box = shape.bounds_of() self.assertEqual(box.min, Point(-math.inf, -math.inf, -math.inf)) self.assertEqual(box.max, Point(math.inf, math.inf, math.inf))