diff --git a/tests/api/hfun.py b/tests/api/hfun.py index 46083de..31a3879 100755 --- a/tests/api/hfun.py +++ b/tests/api/hfun.py @@ -481,17 +481,11 @@ def test_hfun_fast_extent(self): hfun_box = ocsmesh.utils.get_mesh_polygons(hfun_msht) # NOTE: It's good enough if it covers most of it (?) - print( - "Areas", - hfun_box.area, - rast_box.area, - rast_box.buffer(-0.005 * np.sqrt(rast_box.area)).area, - rast_box.buffer(-0.005 * np.sqrt(rast_box.area)).difference( - hfun_box).area - ) - self.assertTrue(hfun_box.covers( - rast_box.buffer(-0.005 * np.sqrt(rast_box.area)) - )) + self.assertTrue( + rast_box.difference(hfun_box).area / rast_box.area < 5e-4 + ) + # This fails due to coarse elements! +# self.assertTrue(hfun_box.covers(rast_box))