MCPcopy Index your code
hub / github.com/ThrowTheSwitch/Unity / UnityAssertDoublesWithin

Function UnityAssertDoublesWithin

src/unity.c:1241–1256  ·  view source on GitHub ↗

-----------------------------------------------*/

Source from the content-addressed store, hash-verified

1239
1240/*-----------------------------------------------*/
1241void UnityAssertDoublesWithin(const UNITY_DOUBLE delta,
1242 const UNITY_DOUBLE expected,
1243 const UNITY_DOUBLE actual,
1244 const char* msg,
1245 const UNITY_LINE_TYPE lineNumber)
1246{
1247 RETURN_IF_FAIL_OR_IGNORE;
1248
1249 if (!UnityDoublesWithin(delta, expected, actual))
1250 {
1251 UnityTestResultsFailBegin(lineNumber);
1252 UNITY_PRINT_EXPECTED_AND_ACTUAL_FLOAT(expected, actual);
1253 UnityAddMsgIfSpecified(msg);
1254 UNITY_FAIL_AND_BAIL;
1255 }
1256}
1257
1258/*-----------------------------------------------*/
1259void UnityAssertDoublesNotWithin(const UNITY_DOUBLE delta,

Callers

nothing calls this directly

Calls 3

UnityDoublesWithinFunction · 0.85
UnityAddMsgIfSpecifiedFunction · 0.85

Tested by

no test coverage detected