1
0
mirror of https://github.com/ThrowTheSwitch/Unity.git synced 2026-01-28 10:44:26 +01:00

Rearrange details to always print if given, no matter if another msg added or not.

Print output on failures no matter if verbose or not.
Enforce that HEX comparisons are unsigned comparisons.
This commit is contained in:
Mark VanderVoord
2022-04-19 16:21:04 -04:00
parent b9e9268d92
commit 0df1d442cb
5 changed files with 94 additions and 17 deletions

View File

@@ -800,6 +800,11 @@ void testHEX32sWithinDelta(void)
TEST_ASSERT_HEX32_WITHIN(5, 5000, 5005);
}
void testHEX32sWithinDeltaShouldIgnoreSign(void)
{
TEST_ASSERT_HEX32_WITHIN(1, 0x7FFFFFFF, 0x80000000);
}
void testHEX32sWithinDeltaAndCustomMessage(void)
{
TEST_ASSERT_HEX32_WITHIN_MESSAGE(1, 5000, 5001, "Custom Message.");
@@ -842,6 +847,11 @@ void testHEX16sWithinDelta(void)
TEST_ASSERT_HEX16_WITHIN(5, 5000, 5005);
}
void testHEX16sWithinDeltaShouldIgnoreSign(void)
{
TEST_ASSERT_HEX16_WITHIN(1, 0x7FFF, 0x8000);
}
void testHEX16sWithinDeltaAndCustomMessage(void)
{
TEST_ASSERT_HEX16_WITHIN_MESSAGE(1, 5000, 5001, "Custom Message.");
@@ -880,6 +890,11 @@ void testHEX8sWithinDelta(void)
TEST_ASSERT_HEX8_WITHIN(5, 1, 4);
}
void testHEX8sWithinDeltaShouldIgnoreSign(void)
{
TEST_ASSERT_HEX8_WITHIN(1, 0x7F, 0x80);
}
void testHEX8sWithinDeltaAndCustomMessage(void)
{
TEST_ASSERT_HEX8_WITHIN_MESSAGE(1, 254, 255, "Custom Message.");