COOLFluiD  Release kernel
COOLFluiD is a Collaborative Simulation Environment (CSE) focused on complex MultiPhysics simulations.
Classes | Functions | Variables
cf3::Tools::Testing Namespace Reference

Classes

struct  Accumulator
 Stores the results of the difference::test() function. More...
 
class  LibTesting
 
class  ProfiledTestFixture
 Any test using this fixture (or a derivative) will be profiled. More...
 
class  TimedTestFixture
 Any test using this fixture (or a derivative) will be timed. More...
 

Functions

void array2d_test (const Table< Real >::ArrayT &a, const Table< Real >::ArrayT &b, Accumulator &result, const std::string &context)
 Compare 2D arrays. More...
 
void array2d_test (const Table< Uint >::ArrayT &a, const Table< Uint >::ArrayT &b, Accumulator &result, const std::string &context)
 Compare 2D arrays. More...
 
void test (const Elements &a, const Elements &b, Accumulator &result)
 Compares Elements. More...
 
void test (const Table< Real > &a, const Table< Real > &b, Accumulator &result)
 Compares Arrays. More...
 
template<typename T >
const Accumulator test (const T &A, const T &B)
 
template<typename T >
void test (const T &A, const T &B, Accumulator &Result)
 
void test (const bool &A, const bool &B, Accumulator &Result)
 Specialization of test() that tests bool. More...
 
void test (const int &A, const int &B, Accumulator &Result)
 Specialization of test that tests int. More...
 
void test (const char &A, const char &B, Accumulator &Result)
 Specialization of test that tests char. More...
 
void test (const Uint &A, const Uint &B, Accumulator &Result)
 Specialization of test that tests Uint. More...
 
void test (const Real &A, const Real &B, Accumulator &Result)
 Specialization of test that tests Real. More...
 
template<typename FirstT , typename SecondT >
void test (const std::pair< FirstT, SecondT > &A, const std::pair< FirstT, SecondT > &B, Accumulator &Result)
 
template<typename IteratorT >
void range_test (IteratorT A, IteratorT LastA, IteratorT B, IteratorT LastB, Accumulator &Result)
 
template<typename VectorT >
void vector_test (const VectorT &A, const VectorT &B, Accumulator &Result)
 Compares vector-like sequences. More...
 
template<int NbRows, int NbCols>
void vector_test (const Eigen::Matrix< Real, NbRows, NbCols > &A, const Eigen::Matrix< Real, NbRows, NbCols > &B, Accumulator &Result)
 Compares Eigen matrices or vectors. More...
 

Variables

cf3::common::RegistLibrary< LibTestinglibTesting
 

Function Documentation

void cf3::Tools::Testing::array2d_test ( const Table< Real >::ArrayT &  a,
const Table< Real >::ArrayT &  b,
Accumulator result,
const std::string &  context 
)

Compare 2D arrays.

Definition at line 32 of file MeshDiff.cpp.

void cf3::Tools::Testing::array2d_test ( const Table< Uint >::ArrayT &  a,
const Table< Uint >::ArrayT &  b,
Accumulator result,
const std::string &  context 
)

Compare 2D arrays.

Definition at line 67 of file MeshDiff.cpp.

void cf3::Tools::Testing::range_test ( IteratorT  A,
IteratorT  LastA,
IteratorT  B,
IteratorT  LastB,
Accumulator Result 
)

Given iterators designating two sequences, calls the test() function for each pair of values, and confirms that both sequences are the same length.

Definition at line 129 of file Difference.hpp.

const Accumulator cf3::Tools::Testing::test ( const T &  A,
const T &  B 
)

Function that tests the difference between two objects, returning separate results for exact (integer and string) and inexact (floating-point) types. See "Comparing floating point numbers" by Bruce Dawson at http://www.cygnus-software.com/papers/comparingfloats/comparingfloats.htm

Definition at line 63 of file Difference.hpp.

void cf3::Tools::Testing::test ( const T &  A,
const T &  B,
Accumulator Result 
)

Function that tests the difference between two objects, returning separate results for exact (integer and string) and inexact (floating-point) types. See "Comparing floating point numbers" by Bruce Dawson at http://www.cygnus-software.com/papers/comparingfloats/comparingfloats.htm

Definition at line 73 of file Difference.hpp.

void cf3::Tools::Testing::test ( const bool &  A,
const bool &  B,
Accumulator Result 
)
inline

Specialization of test() that tests bool.

Definition at line 80 of file Difference.hpp.

void cf3::Tools::Testing::test ( const int &  A,
const int &  B,
Accumulator Result 
)
inline

Specialization of test that tests int.

Definition at line 86 of file Difference.hpp.

void cf3::Tools::Testing::test ( const char &  A,
const char &  B,
Accumulator Result 
)
inline

Specialization of test that tests char.

Definition at line 92 of file Difference.hpp.

void cf3::Tools::Testing::test ( const Uint A,
const Uint B,
Accumulator Result 
)
inline

Specialization of test that tests Uint.

Definition at line 98 of file Difference.hpp.

void cf3::Tools::Testing::test ( const Elements a,
const Elements b,
Accumulator result 
)

Compares Elements.

Definition at line 98 of file MeshDiff.cpp.

void cf3::Tools::Testing::test ( const Real &  A,
const Real &  B,
Accumulator Result 
)
inline

Specialization of test that tests Real.

Definition at line 104 of file Difference.hpp.

void cf3::Tools::Testing::test ( const Table< Real > &  a,
const Table< Real > &  b,
Accumulator result 
)

Compares Arrays.

Definition at line 107 of file MeshDiff.cpp.

void cf3::Tools::Testing::test ( const std::pair< FirstT, SecondT > &  A,
const std::pair< FirstT, SecondT > &  B,
Accumulator Result 
)
inline

Definition at line 120 of file Difference.hpp.

void cf3::Tools::Testing::vector_test ( const VectorT &  A,
const VectorT &  B,
Accumulator Result 
)

Compares vector-like sequences.

Definition at line 139 of file Difference.hpp.

void cf3::Tools::Testing::vector_test ( const Eigen::Matrix< Real, NbRows, NbCols > &  A,
const Eigen::Matrix< Real, NbRows, NbCols > &  B,
Accumulator Result 
)

Compares Eigen matrices or vectors.

Definition at line 151 of file Difference.hpp.

Variable Documentation

Definition at line 17 of file LibTesting.cpp.

Send comments to:
COOLFluiD Web Admin