Gromacs  2024.3
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Classes | Functions
testmatchers.h File Reference
#include <memory>
#include <ostream>
#include <tuple>
#include <gmock/gmock.h>
#include "gromacs/utility/real.h"
+ Include dependency graph for testmatchers.h:
+ This graph shows which files directly or indirectly include this file:

Description

Extra GoogleMock matchers for unit tests.

This file provides the usual kind of GoogleMock matchers that extend the usefulness of GoogleMock EXPECT_THAT constructs to the kinds of containers of reals commonly used. This means that test code can write one-liners rather than loops over whole containers.

Author
Mark Abraham mark..nosp@m.j.ab.nosp@m.raham.nosp@m.@gma.nosp@m.il.co.nosp@m.m

Classes

class  gmx::BasicVector< ValueType >
 C++ class for 3D vectors. More...
 

Functions

testing::Matcher< std::tuple
< float, float > > 
gmx::test::FloatEq (const FloatingPointTolerance &tolerance)
 Make matcher for floats for use with GoogleMock that compare equal when tolerance is satisifed. More...
 
testing::Matcher< std::tuple
< double, double > > 
gmx::test::DoubleEq (const FloatingPointTolerance &tolerance)
 Make matcher for doubles for use with GoogleMock that compare equal when tolerance is satisifed. More...
 
testing::Matcher< std::tuple
< real, real > > 
gmx::test::RealEq (const FloatingPointTolerance &tolerance)
 Make matcher for reals for use with GoogleMock that compare equal when tolerance is satisifed. More...
 
testing::Matcher< std::tuple
< BasicVector< real >
, BasicVector< real > > > 
gmx::test::RVecEq (const FloatingPointTolerance &tolerance)
 Make matcher for RVecs for use with GoogleMock that compare equal when tolerance is satisifed. More...