diff --git a/src/main/c/Georg/tictactoe.c b/src/main/c/Georg/tictactoe.c index 87680a0..c97a735 100644 --- a/src/main/c/Georg/tictactoe.c +++ b/src/main/c/Georg/tictactoe.c @@ -2,3 +2,7 @@ #include #include "tictactoe.h" + +char* getWelcomeMessage(){ + return "Hallo und willkommen zu unserem TicTacToe Spiel. Anbei die Anleitung:\n"; +} \ No newline at end of file diff --git a/src/main/c/Georg/tictactoe.h b/src/main/c/Georg/tictactoe.h index ca8f3ae..9ac6a1f 100644 --- a/src/main/c/Georg/tictactoe.h +++ b/src/main/c/Georg/tictactoe.h @@ -1,5 +1,6 @@ #ifndef TICTACTOE_H #define TICTACTOE_H +char* getWelcomeMessage(); #endif //TICTACTOE_H diff --git a/src/test/c/Georg/test_tictactoe.c b/src/test/c/Georg/test_tictactoe.c index 95b2edc..05fa62c 100644 --- a/src/test/c/Georg/test_tictactoe.c +++ b/src/test/c/Georg/test_tictactoe.c @@ -13,3 +13,13 @@ void test_compileTest_shutBeAllwaysTrue(void){ TEST_ASSERT_EQUAL_INT(1,1); } +void test_welcome_message(void){ + // arrange + char* expectedMessage = "Hallo und willkommen zu unserem TicTacToe Spiel. Anbei die Anleitung:\n"; + + // act + char* message = getWelcomeMessage(); + + // aassert + TEST_ASSERT_EQUAL_STRING(expectedMessage, message); +} \ No newline at end of file