|
@ -5,6 +5,7 @@ |
|
|
#include "inputHandling.h" |
|
|
#include "inputHandling.h" |
|
|
char halloWelt[]="Hallo Welt"; |
|
|
char halloWelt[]="Hallo Welt"; |
|
|
char halloWelt2[]="Hallo Welt"; |
|
|
char halloWelt2[]="Hallo Welt"; |
|
|
|
|
|
char halloWelt3[]="Ha llo W el t "; |
|
|
|
|
|
|
|
|
void setUp(void) |
|
|
void setUp(void) |
|
|
{ |
|
|
{ |
|
@ -22,8 +23,14 @@ void test_inputHandling_deleteOneWhiteSpace(void) |
|
|
|
|
|
|
|
|
void test_inputHandling_deleteTwoWhiteSpaces(void) |
|
|
void test_inputHandling_deleteTwoWhiteSpaces(void) |
|
|
{ |
|
|
{ |
|
|
deleteWhitespace(halloWelt, 11); |
|
|
|
|
|
TEST_ASSERT_EQUAL_STRING("HalloWelt", halloWelt); |
|
|
|
|
|
|
|
|
deleteWhitespace(halloWelt2, 11); |
|
|
|
|
|
TEST_ASSERT_EQUAL_STRING("HalloWelt", halloWelt2); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
void test_inputHandling_deleteManyWhiteSpaces(void) |
|
|
|
|
|
{ |
|
|
|
|
|
deleteWhitespace(halloWelt3, 16); |
|
|
|
|
|
TEST_ASSERT_EQUAL_STRING("HalloWelt", halloWelt3); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
#endif // TEST |
|
|
#endif // TEST |