Merge release-5-0 into master
[alexxy/gromacs.git] / src / gromacs / analysisdata / tests / datatest.h
index 579c6211d47f8de1dfad39d9c03836a3022df867..6d85dd6b05c080827daef2ca26cb912b77ab9b2b 100644 (file)
 
 #include <gtest/gtest.h>
 
-#include "gromacs/legacyheaders/types/simple.h"
-
 #include "gromacs/analysisdata/dataframe.h"
 #include "gromacs/utility/gmxassert.h"
+#include "gromacs/utility/real.h"
 
 #include "testutils/refdata.h"
 
+// currently the bug manifests itself only in AbstractAnalysisData testing
+#if (defined __ICL && __ICL >= 1400) || (defined __ICC && __ICC >= 1400) || (defined __PATHSCALE__)
+#define STATIC_ANON_NAMESPACE_BUG //see #1558 for details
+#endif
+
 namespace gmx
 {
 
@@ -64,6 +68,8 @@ class AnalysisDataHandle;
 namespace test
 {
 
+class FloatingPointTolerance;
+
 /*! \libinternal \brief
  * Represents a single set of points in AnalysisDataTestInputFrame structure.
  *
@@ -414,9 +420,10 @@ class AnalysisDataTestFixture : public ::testing::Test
         /*! \brief
          * Adds a mock module that verifies output against reference data.
          *
-         * \param[in]  checker  Reference data checker to use for comparison.
-         * \param[in]  id       Identifier for reference data compound to use.
-         * \param      source   Data object to verify.
+         * \param[in]  checker   Reference data checker to use for comparison.
+         * \param[in]  id        Identifier for reference data compound to use.
+         * \param      source    Data object to verify.
+         * \param[in]  tolerance Tolerance to use for comparison.
          *
          * Creates a mock module that verifies that the
          * AnalysisDataModuleInterface methods are called correctly by
@@ -428,9 +435,10 @@ class AnalysisDataTestFixture : public ::testing::Test
          *
          * \see TestReferenceData
          */
-        static void addReferenceCheckerModule(TestReferenceChecker  checker,
-                                              const char           *id,
-                                              AbstractAnalysisData *source);
+        static void addReferenceCheckerModule(TestReferenceChecker          checker,
+                                              const char                   *id,
+                                              AbstractAnalysisData         *source,
+                                              const FloatingPointTolerance &tolerance);
 
         /*! \brief
          * Adds a mock module that verifies output against reference data.