Browse Source

Freies Feld als true ausgeben

remotes/origin/homan
fdai7892 11 months ago
parent
commit
285b28bfc3
  1. 11
      src/test/test_duellist_spielesammlung_projekt.c

11
src/test/test_duellist_spielesammlung_projekt.c

@ -199,7 +199,18 @@ void test_getCurrentPlayer_returns_correct_player(void) {
// Assert
TEST_ASSERT_EQUAL(PLAYER_O, currentPlayer);
}
void test_FieldEmpty_returns_true_for_empty_field(void) {
// Arrange
TicTacToeGame game = { .board = {{PLAYER_X, EMPTY, EMPTY},
{EMPTY, PLAYER_O, EMPTY},
{EMPTY, EMPTY, EMPTY}} };
// Act
int result = FieldEmpty(&game, 0, 2);
// Assert
TEST_ASSERT_EQUAL(1, result);
}

Loading…
Cancel
Save