ECCE @ EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
FloatComparisons.hpp File Reference
#include <algorithm>
#include <limits>
#include <boost/test/unit_test.hpp>
#include "Acts/Utilities/Definitions.hpp"
+ Include dependency graph for FloatComparisons.hpp:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  Acts
 Set the Geometry Context PLUGIN.
 
namespace  Acts::Test
 Namespace for ATS unit tests.
 
namespace  Acts::Test::float_compare_internal
 

Macros

#define CHECK_CLOSE_REL(val, ref, reltol)   BOOST_CHECK(Acts::Test::checkCloseRel((val), (ref), (reltol)))
 
#define CHECK_CLOSE_ABS(val, ref, abstol)   BOOST_CHECK(Acts::Test::checkCloseAbs((val), (ref), (abstol)))
 
#define CHECK_SMALL(val, small)   BOOST_CHECK(Acts::Test::checkSmall((val), (small)))
 
#define CHECK_CLOSE_OR_SMALL(val, ref, reltol, small)   BOOST_CHECK(Acts::Test::checkCloseOrSmall((val), (ref), (reltol), (small)))
 
#define CHECK_CLOSE_COVARIANCE(val, ref, tol)   BOOST_CHECK(Acts::Test::checkCloseCovariance((val), (ref), (tol)))
 

Typedefs

using Acts::Test::float_compare_internal::predicate_result = boost::test_tools::predicate_result
 
using Acts::Test::float_compare_internal::ScalarComparison = std::function< predicate_result(double, double)>
 

Functions

ScalarComparison Acts::Test::float_compare_internal::closeOrSmall (double reltol, double small)
 
ScalarComparison Acts::Test::float_compare_internal::closeAbs (double abstol)
 
template<typename Derived1 , typename Derived2 >
predicate_result Acts::Test::float_compare_internal::matrixCompare (const Eigen::DenseBase< Derived1 > &val, const Eigen::DenseBase< Derived2 > &ref, ScalarComparison &&compareImpl)
 
template<typename Container , typename Enable = typename Container::const_iterator>
predicate_result Acts::Test::float_compare_internal::compare (const Container &val, const Container &ref, ScalarComparison &&compareImpl)
 
template<typename T , typename U >
predicate_result Acts::Test::float_compare_internal::compare (const Eigen::DenseBase< T > &val, const Eigen::DenseBase< U > &ref, ScalarComparison &&compareImpl)
 
predicate_result Acts::Test::float_compare_internal::compare (const Transform3D &val, const Transform3D &ref, ScalarComparison &&compareImpl)
 
predicate_result Acts::Test::float_compare_internal::compare (double val, double ref, ScalarComparison &&compareImpl)
 
template<typename T , typename U >
boost::test_tools::predicate_result Acts::Test::checkCloseRel (const T &val, const U &ref, double reltol)
 
template<typename T , typename U >
boost::test_tools::predicate_result Acts::Test::checkCloseAbs (const T &val, const U &ref, double abstol)
 
template<typename T >
boost::test_tools::predicate_result Acts::Test::checkSmall (const T &val, double small)
 
template<typename T , typename U >
boost::test_tools::predicate_result Acts::Test::checkCloseOrSmall (const T &val, const U &ref, double reltol, double small)
 
template<typename Scalar , int dim>
boost::test_tools::predicate_result Acts::Test::checkCloseCovariance (const ActsSymMatrix< Scalar, dim > &val, const ActsSymMatrix< Scalar, dim > &ref, double tol)
 

Macro Definition Documentation

#define CHECK_CLOSE_ABS (   val,
  ref,
  abstol 
)    BOOST_CHECK(Acts::Test::checkCloseAbs((val), (ref), (abstol)))
#define CHECK_CLOSE_COVARIANCE (   val,
  ref,
  tol 
)    BOOST_CHECK(Acts::Test::checkCloseCovariance((val), (ref), (tol)))

Definition at line 53 of file FloatComparisons.hpp.

View newest version in sPHENIX GitHub at line 53 of file FloatComparisons.hpp

Referenced by Acts::Test::BOOST_AUTO_TEST_CASE(), and BOOST_DATA_TEST_CASE().

#define CHECK_CLOSE_OR_SMALL (   val,
  ref,
  reltol,
  small 
)    BOOST_CHECK(Acts::Test::checkCloseOrSmall((val), (ref), (reltol), (small)))

Definition at line 45 of file FloatComparisons.hpp.

View newest version in sPHENIX GitHub at line 45 of file FloatComparisons.hpp

Referenced by Acts::Test::BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), Acts::Test::BOOST_DATA_TEST_CASE(), and Acts::Test::testJacobianToGlobal().

#define CHECK_SMALL (   val,
  small 
)    BOOST_CHECK(Acts::Test::checkSmall((val), (small)))

Definition at line 39 of file FloatComparisons.hpp.

View newest version in sPHENIX GitHub at line 39 of file FloatComparisons.hpp

Referenced by BOOST_AUTO_TEST_CASE(), Acts::Test::BOOST_AUTO_TEST_CASE(), and Acts::Test::BOOST_FIXTURE_TEST_CASE().