From 7a7cbc3182b5b57c7825df6c47bb07b6178d4b1b Mon Sep 17 00:00:00 2001 From: Simon Hildebrandt Date: Wed, 7 Feb 2024 15:28:06 +0100 Subject: [PATCH] =?UTF-8?q?11=20f=C3=BCnfter=20Test?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- 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 57809a8..d65895b 100644 --- a/src/test/c/test_TicTacToe.c +++ b/src/test/c/test_TicTacToe.c @@ -72,6 +72,22 @@ void test_TicTacToe_Winner_O_col_1(void) /* act */ actual = Winner(board); + /* assert */ + TEST_ASSERT_EQUAL_INT(expected, actual); +} +void test_TicTacToe_Winner_X_col_2(void) +{ + /* arrange */ + int expected = 1; + int actual; + char board[3][3] = { + {'O', 'X', 'X'}, + {'_', 'X', 'O'}, + {'O', 'X', '_'} + }; + /* act */ + actual = Winner(board); + /* assert */ TEST_ASSERT_EQUAL_INT(expected, actual); } \ No newline at end of file