From f69fbe8a95c24935fa62cb04e72fb348f962296f Mon Sep 17 00:00:00 2001 From: Dom Postorivo Date: Sat, 13 Apr 2019 11:45:27 -0400 Subject: [PATCH] expliticly show test failures of unequal strings --- test/tests/testunity.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/test/tests/testunity.c b/test/tests/testunity.c index 366deba..bba555a 100644 --- a/test/tests/testunity.c +++ b/test/tests/testunity.c @@ -1852,6 +1852,20 @@ void testNotEqualStringLen_ActualStringIsNull(void) VERIFY_FAILS_END } +void testNotEqualString_ExpectedStringIsLonger(void) +{ + EXPECT_ABORT_BEGIN + TEST_ASSERT_EQUAL_STRING("foo2", "foo"); + VERIFY_FAILS_END +} + +void testNotEqualString_ActualStringIsLonger(void) +{ + EXPECT_ABORT_BEGIN + TEST_ASSERT_EQUAL_STRING("foo", "foo2"); + VERIFY_FAILS_END +} + void testEqualStringArrays(void) { const char *testStrings[] = { "foo", "boo", "woo", "moo" };