From 535f9a54b0c30211d50629c07034ca212c372f54 Mon Sep 17 00:00:00 2001 From: Simon Hildebrandt Date: Wed, 7 Feb 2024 13:06:34 +0100 Subject: [PATCH] 7 zweiter Test --- src/test/c/test_TicTacToe.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/src/test/c/test_TicTacToe.c b/src/test/c/test_TicTacToe.c index b1c8b25..f8a1c62 100644 --- a/src/test/c/test_TicTacToe.c +++ b/src/test/c/test_TicTacToe.c @@ -26,4 +26,20 @@ void test_TicTacToe_Winner_X_line_1(void) /* assert */ TEST_ASSERT_EQUAL_INT(expected, actual); +} +void test_TicTacToe_Winner_O_line_2(void) +{ + /* arrange */ + int expected = 2; + int actual; + char board[3][3] = { + {'X', 'O', 'X'}, + {'O', 'O', 'O'}, + {'O', 'X', 'X'} + }; + /* act */ + actual = Winner(board); + + /* assert */ + TEST_ASSERT_EQUAL_INT(expected, actual); } \ No newline at end of file