From 98ba967d824ecf9e6ef297eddc431d0ce44b905d Mon Sep 17 00:00:00 2001 From: Sophia Weber Date: Sun, 28 Jan 2024 13:02:33 +0100 Subject: [PATCH] Finished Whitespace Function Tests --- test/test_inputHandling.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/test/test_inputHandling.c b/test/test_inputHandling.c index 9fb4730..0c16125 100644 --- a/test/test_inputHandling.c +++ b/test/test_inputHandling.c @@ -6,6 +6,7 @@ char halloWelt[]="Hallo Welt"; char halloWelt2[]="Hallo Welt"; char halloWelt3[]="Ha llo W el t "; +char halloWelt4[]="Ha\n\nllo \r W el\r\r t "; void setUp(void) { @@ -33,4 +34,10 @@ void test_inputHandling_deleteManyWhiteSpaces(void) TEST_ASSERT_EQUAL_STRING("HalloWelt", halloWelt3); } +void test_inputHandling_deleteAllOtherCharacter(void) +{ + deleteWhitespace(halloWelt4, 19); + TEST_ASSERT_EQUAL_STRING("HalloWelt", halloWelt4); +} + #endif // TEST