From 8c6ab56e0de12905747b59f8f04309f0b5f5970b Mon Sep 17 00:00:00 2001 From: Matthias Maier Date: Fri, 23 Jun 2023 17:26:52 -0500 Subject: [PATCH] Test cgal/cgal_triangulation_06: disable floating point exceptions Otherwise this test might trigger a spurious floating point exception depending on the CGAL library version being used. --- tests/cgal/cgal_triangulation_06.cc | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/cgal/cgal_triangulation_06.cc b/tests/cgal/cgal_triangulation_06.cc index 9be5c04034..517d3902dd 100644 --- a/tests/cgal/cgal_triangulation_06.cc +++ b/tests/cgal/cgal_triangulation_06.cc @@ -45,6 +45,16 @@ using C3t3 = CGAL::Mesh_complex_3_in_triangulation_3; int main() { + // This test might trigger spurious floating point exception despite + // functioning properly. Simply disable floating point exceptions again + // (after they had been enabled int tests.h) +#if defined(DEBUG) && defined(DEAL_II_HAVE_FP_EXCEPTIONS) + { + const int current_fe_except = fegetexcept(); + fedisableexcept(current_fe_except); + } +#endif + initlog(); // Build a deal.II triangulation CGAL::Surface_mesh cgal_surface_mesh; -- 2.39.5