mirror of
https://github.com/ThrowTheSwitch/Unity.git
synced 2026-01-27 18:24:27 +01:00
- Applied details to FAIL messages as well
This commit is contained in:
27
src/unity.c
27
src/unity.c
@@ -1210,13 +1210,28 @@ void UnityFail(const char* msg, const UNITY_LINE_TYPE line)
|
|||||||
UnityPrintFail();
|
UnityPrintFail();
|
||||||
if (msg != NULL)
|
if (msg != NULL)
|
||||||
{
|
{
|
||||||
UNITY_OUTPUT_CHAR(':');
|
UNITY_OUTPUT_CHAR(':');
|
||||||
if (msg[0] != ' ')
|
|
||||||
{
|
#ifndef UNITY_EXCLUDE_DETAILS
|
||||||
UNITY_OUTPUT_CHAR(' ');
|
if (Unity.CurrentDetail1)
|
||||||
}
|
{
|
||||||
UnityPrint(msg);
|
UnityPrint(UnityStrDetail1Name);
|
||||||
|
UnityPrint(Unity.CurrentDetail1);
|
||||||
|
if (Unity.CurrentDetail2)
|
||||||
|
{
|
||||||
|
UnityPrint(UnityStrDetail2Name);
|
||||||
|
UnityPrint(Unity.CurrentDetail2);
|
||||||
|
}
|
||||||
|
UnityPrint(UnityStrSpacer);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
if (msg[0] != ' ')
|
||||||
|
{
|
||||||
|
UNITY_OUTPUT_CHAR(' ');
|
||||||
|
}
|
||||||
|
UnityPrint(msg);
|
||||||
}
|
}
|
||||||
|
|
||||||
UNITY_FAIL_AND_BAIL;
|
UNITY_FAIL_AND_BAIL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user