A result of an engine test. Each test can return multiple results.
More...
#include <EngineTest.hpp>
|
| Result (const std::string &name, const std::string &description) |
| Construct a new result. More...
|
|
void | addValue (double time, double val) |
| Add a value to the result. More...
|
|
void | addValues (double time, const rw::math::Q &vals) |
| Add multiple values to the result. More...
|
|
void | checkLastValues (double expected, double eps=std::numeric_limits< double >::epsilon()) |
| Check if the latest added value was as expected and add a failure if not. More...
|
|
void | checkLastValuesBetween (double expectedLow, double expectedHigh, double eps=std::numeric_limits< double >::epsilon()) |
| Check if the latest added value was in expected range, [expectedLow; expectedHigh ], and add a failure if not. More...
|
|
A result of an engine test. Each test can return multiple results.
◆ Result()
Result |
( |
const std::string & |
name, |
|
|
const std::string & |
description |
|
) |
| |
Construct a new result.
- Parameters
-
name | [in] name of the result. |
description | [in] description of the result. |
◆ addValue()
void addValue |
( |
double |
time, |
|
|
double |
val |
|
) |
| |
Add a value to the result.
- Parameters
-
time | [in] simulation time. |
val | [in] the value to record. |
◆ addValues()
void addValues |
( |
double |
time, |
|
|
const rw::math::Q & |
vals |
|
) |
| |
Add multiple values to the result.
- Parameters
-
time | [in] simulation time. |
vals | [in] the values to record. |
◆ checkLastValues()
void checkLastValues |
( |
double |
expected, |
|
|
double |
eps = std::numeric_limits< double >::epsilon() |
|
) |
| |
Check if the latest added value was as expected and add a failure if not.
- Parameters
-
expected | [in] the expected value. |
eps | [in] (optional) the tolerance. |
- Note
- For Q values with 2 or more values, these are compared to the same expected value.
◆ checkLastValuesBetween()
void checkLastValuesBetween |
( |
double |
expectedLow, |
|
|
double |
expectedHigh, |
|
|
double |
eps = std::numeric_limits< double >::epsilon() |
|
) |
| |
Check if the latest added value was in expected range, [expectedLow; expectedHigh ], and add a failure if not.
- Parameters
-
expectedLow | [in] lower bound. |
expectedHigh | [in] higher bound. |
eps | [in] (optional) the tolerance. |
- Note
- For Q values with 2 or more values, these are compared to the same values.
The documentation for this struct was generated from the following file: