|
|
@ -145,5 +145,19 @@ void test_istzugerlaubt_Turm(void){ |
|
|
|
} |
|
|
|
free(brett); |
|
|
|
} |
|
|
|
void test_Laeufer_black_Moving(void) { |
|
|
|
char** brett = Schachbrett_erstellen(); |
|
|
|
Player player = PLAYER_BLACK; |
|
|
|
// Prüfen, ob der Zug eine Diagonale ist == true |
|
|
|
brett[6][6] = 'b'; |
|
|
|
TEST_ASSERT_TRUE(istzugerlaubt(brett, 6, 6, 3, 3, player)); |
|
|
|
|
|
|
|
for (int i = 0; i < 8; i++) { |
|
|
|
free(brett[i]); |
|
|
|
} |
|
|
|
free(brett); |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
#endif // TEST |