Browse Source

bug fix2 + include math.h

main
Daniel M 11 months ago
parent
commit
4c3a262987
  1. 136
      build/test/cache/test_duellist_spielesammlung_projekt.c
  2. BIN
      build/test/out/c/duellist-spielesammlung-projekt.o
  3. BIN
      build/test/out/c/test_duellist_spielesammlung_projekt.o
  4. BIN
      build/test/out/c/test_duellist_spielesammlung_projekt_runner.o
  5. 136
      build/test/preprocess/files/test_duellist_spielesammlung_projekt.c
  6. 126
      build/test/runners/test_duellist_spielesammlung_projekt_runner.c
  7. 1
      src/main/duellist-spielesammlung-projekt.c

136
build/test/cache/test_duellist_spielesammlung_projekt.c

@ -14,8 +14,6 @@ void tearDown(void) {}
void test_coinflip_x_starts(void) { void test_coinflip_x_starts(void) {
@ -36,9 +34,9 @@ void test_coinflip_x_starts(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(19), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(18), UNITY_DISPLAY_STYLE_INT);
do {if ((game.currentPlayer == PLAYER_X || game.currentPlayer == PLAYER_O)) {} else {UnityFail( ((" Expected TRUE Was FALSE")), (UNITY_UINT)((UNITY_UINT)(20)));}} while(0);
do {if ((game.currentPlayer == PLAYER_X || game.currentPlayer == PLAYER_O)) {} else {UnityFail( ((" Expected TRUE Was FALSE")), (UNITY_UINT)((UNITY_UINT)(19)));}} while(0);
} }
@ -64,9 +62,9 @@ void test_coinflip_o_starts(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(31), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(30), UNITY_DISPLAY_STYLE_INT);
do {if ((game.currentPlayer == PLAYER_X || game.currentPlayer == PLAYER_O)) {} else {UnityFail( ((" Expected TRUE Was FALSE")), (UNITY_UINT)((UNITY_UINT)(32)));}} while(0);
do {if ((game.currentPlayer == PLAYER_X || game.currentPlayer == PLAYER_O)) {} else {UnityFail( ((" Expected TRUE Was FALSE")), (UNITY_UINT)((UNITY_UINT)(31)));}} while(0);
} }
@ -98,7 +96,7 @@ void test_vertical_win(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(46), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(45), UNITY_DISPLAY_STYLE_INT);
} }
@ -130,7 +128,7 @@ void test_horizontal_win(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(60), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(59), UNITY_DISPLAY_STYLE_INT);
} }
@ -160,7 +158,7 @@ void test_diagonal_win(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(73), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(72), UNITY_DISPLAY_STYLE_INT);
} }
@ -192,13 +190,13 @@ void test_valid_move_and_switch(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(87), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(86), UNITY_DISPLAY_STYLE_INT);
UnityAssertEqualNumber((UNITY_INT)((PLAYER_O)), (UNITY_INT)((game.currentPlayer)), ( UnityAssertEqualNumber((UNITY_INT)((PLAYER_O)), (UNITY_INT)((game.currentPlayer)), (
((void *)0) ((void *)0)
), (UNITY_UINT)(88), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(87), UNITY_DISPLAY_STYLE_INT);
} }
@ -232,7 +230,7 @@ void test_invalid_input(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(103), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(102), UNITY_DISPLAY_STYLE_INT);
} }
@ -264,7 +262,7 @@ void test_valid_input(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(117), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(116), UNITY_DISPLAY_STYLE_INT);
} }
@ -298,7 +296,7 @@ void test_invalid_input_negative_row(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(132), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(131), UNITY_DISPLAY_STYLE_INT);
} }
@ -330,7 +328,7 @@ void test_invalid_input_overflow_column(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(146), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(145), UNITY_DISPLAY_STYLE_INT);
} }
@ -362,7 +360,7 @@ void test_NumberOfMoves_returns_correct_number_of_moves(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(160), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(159), UNITY_DISPLAY_STYLE_INT);
} }
@ -390,7 +388,7 @@ void test_BoardFull_returns_false_when_board_is_not_full(void) {
do {if (!(boardFull)) {} else {UnityFail( ((" Expected FALSE Was TRUE")), (UNITY_UINT)((UNITY_UINT)(174)));}} while(0);
do {if (!(boardFull)) {} else {UnityFail( ((" Expected FALSE Was TRUE")), (UNITY_UINT)((UNITY_UINT)(173)));}} while(0);
} }
@ -416,7 +414,7 @@ void test_BoardFull_returns_true_when_board_is_full(void) {
do {if ((boardFull)) {} else {UnityFail( ((" Expected TRUE Was FALSE")), (UNITY_UINT)((UNITY_UINT)(187)));}} while(0);
do {if ((boardFull)) {} else {UnityFail( ((" Expected TRUE Was FALSE")), (UNITY_UINT)((UNITY_UINT)(186)));}} while(0);
} }
@ -446,7 +444,7 @@ void test_CurrentPlayer_returns_correct_player(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(200), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(199), UNITY_DISPLAY_STYLE_INT);
} }
@ -474,7 +472,7 @@ void test_FieldEmpty_returns_true_for_empty_field(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(212), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(211), UNITY_DISPLAY_STYLE_INT);
} }
@ -504,7 +502,7 @@ void test_FieldEmpty_returns_false_for_nonempty_field(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(225), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(224), UNITY_DISPLAY_STYLE_INT);
} }
@ -536,7 +534,7 @@ void test_calculate_mines_HeightWidthOne(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(239), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(238), UNITY_DISPLAY_STYLE_INT);
} }
@ -568,7 +566,7 @@ void test_calculate_mines_WidthOne(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(253), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(252), UNITY_DISPLAY_STYLE_INT);
} }
@ -600,7 +598,7 @@ void test_calculate_mines_NormalCase(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(267), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(266), UNITY_DISPLAY_STYLE_INT);
} }
@ -642,7 +640,7 @@ void test_end_check_AllUncovered_NoMines(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(286), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(285), UNITY_DISPLAY_STYLE_INT);
} }
@ -674,7 +672,7 @@ void test_create_minefield_ValidDimensions(void)
((void *)0) ((void *)0)
)) {} else {UnityFail( (((" Expected Non-NULL"))), (UNITY_UINT)((UNITY_UINT)((UNITY_UINT)(300))));}} while(0);
)) {} else {UnityFail( (((" Expected Non-NULL"))), (UNITY_UINT)((UNITY_UINT)((UNITY_UINT)(299))));}} while(0);
for (int i = 0; i < height; i++) { for (int i = 0; i < height; i++) {
@ -682,7 +680,7 @@ void test_create_minefield_ValidDimensions(void)
((void *)0) ((void *)0)
)) {} else {UnityFail( (((" Expected Non-NULL"))), (UNITY_UINT)((UNITY_UINT)((UNITY_UINT)(302))));}} while(0);
)) {} else {UnityFail( (((" Expected Non-NULL"))), (UNITY_UINT)((UNITY_UINT)((UNITY_UINT)(301))));}} while(0);
for (int j = 0; j < width; j++) { for (int j = 0; j < width; j++) {
@ -690,7 +688,7 @@ void test_create_minefield_ValidDimensions(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(304), UNITY_DISPLAY_STYLE_CHAR);
), (UNITY_UINT)(303), UNITY_DISPLAY_STYLE_CHAR);
} }
@ -736,7 +734,7 @@ void test_calculate_mines_HeightOne(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(325), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(324), UNITY_DISPLAY_STYLE_INT);
} }
@ -768,7 +766,7 @@ void test_create_minefield_NegativeDimensions(void)
((void *)0) ((void *)0)
)) {} else {UnityFail( (((" Expected NULL"))), (UNITY_UINT)((UNITY_UINT)((UNITY_UINT)(339))));}} while(0);
)) {} else {UnityFail( (((" Expected NULL"))), (UNITY_UINT)((UNITY_UINT)((UNITY_UINT)(338))));}} while(0);
} }
@ -800,7 +798,7 @@ void test_calculate_mines_HeightZero(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(353), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(352), UNITY_DISPLAY_STYLE_INT);
} }
@ -832,7 +830,7 @@ void test_calculate_mines_HeightWidthNumber(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(367), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(366), UNITY_DISPLAY_STYLE_INT);
} }
@ -864,7 +862,7 @@ void test_calculate_mines_HeightWidthAgan(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(381), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(380), UNITY_DISPLAY_STYLE_INT);
} }
@ -896,7 +894,7 @@ void test_calculate_mines_HeightWidthRoundUp(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(395), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(394), UNITY_DISPLAY_STYLE_INT);
} }
@ -928,7 +926,7 @@ void test_calculate_mines_HeightWidthNoRound(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(409), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(408), UNITY_DISPLAY_STYLE_INT);
} }
@ -960,10 +958,12 @@ void test_calculate_mines_HeightWidthFinal(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(423), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(422), UNITY_DISPLAY_STYLE_INT);
} }
void test_generateRandomNumber_withinValidRange(void) void test_generateRandomNumber_withinValidRange(void)
{ {
@ -980,7 +980,7 @@ void test_generateRandomNumber_withinValidRange(void)
do {if ((result >= 1 && result <= 100)) {} else {UnityFail( ((" Expected TRUE Was FALSE")), (UNITY_UINT)((UNITY_UINT)(459)));}} while(0);
do {if ((result >= 1 && result <= 100)) {} else {UnityFail( ((" Expected TRUE Was FALSE")), (UNITY_UINT)((UNITY_UINT)(433)));}} while(0);
} }
@ -1010,7 +1010,7 @@ void test_addition(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(472), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(446), UNITY_DISPLAY_STYLE_INT);
} }
@ -1040,7 +1040,7 @@ void test_subtraction(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(485), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(459), UNITY_DISPLAY_STYLE_INT);
} }
@ -1072,7 +1072,7 @@ void test_multiplication(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(499), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(473), UNITY_DISPLAY_STYLE_INT);
} }
@ -1102,7 +1102,7 @@ void test_division(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(512), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(486), UNITY_DISPLAY_STYLE_INT);
} }
@ -1132,7 +1132,7 @@ void test_division_byZero_returnsZero(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(525), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(499), UNITY_DISPLAY_STYLE_INT);
} }
@ -1162,7 +1162,7 @@ void test_modulo(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(538), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(512), UNITY_DISPLAY_STYLE_INT);
} }
@ -1192,7 +1192,7 @@ void test_compare_equalNumbers(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(551), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(525), UNITY_DISPLAY_STYLE_INT);
} }
@ -1222,7 +1222,7 @@ void test_compare_aLessThanB(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(564), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(538), UNITY_DISPLAY_STYLE_INT);
} }
@ -1252,7 +1252,7 @@ void test_compare_aGreaterThanB(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(577), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(551), UNITY_DISPLAY_STYLE_INT);
} }
@ -1282,7 +1282,7 @@ void test_exponentiation(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(590), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(564), UNITY_DISPLAY_STYLE_INT);
} }
@ -1312,7 +1312,7 @@ void test_exponentiation_negativeExponent(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(603), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(577), UNITY_DISPLAY_STYLE_INT);
} }
@ -1340,7 +1340,7 @@ void test_squareRoot_validNumber(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(615), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(589), UNITY_DISPLAY_STYLE_INT);
} }
@ -1368,7 +1368,7 @@ void test_squareRoot_negativeNumber(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(627), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(601), UNITY_DISPLAY_STYLE_INT);
} }
@ -1492,12 +1492,6 @@ void test_getUserAnswer_invalidInput(void)
void test_bereichauswahl_gueltige_eingabe(void) void test_bereichauswahl_gueltige_eingabe(void)
{ {
@ -1520,7 +1514,7 @@ void test_bereichauswahl_gueltige_eingabe(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(697), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(668), UNITY_DISPLAY_STYLE_INT);
} }
@ -1548,7 +1542,7 @@ void test_bereichauswahl_ungueltige_eingabe(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(709), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(680), UNITY_DISPLAY_STYLE_INT);
} }
@ -1576,7 +1570,7 @@ void test_bereichfalsch_gueltige_eingabe(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(721), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(692), UNITY_DISPLAY_STYLE_INT);
} }
@ -1604,7 +1598,7 @@ void test_bereichfalsch_ungueltige_eingabe(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(733), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(704), UNITY_DISPLAY_STYLE_INT);
} }
@ -1634,7 +1628,7 @@ void test_bereich1_richtige_antwort(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(746), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(717), UNITY_DISPLAY_STYLE_INT);
} }
@ -1664,7 +1658,7 @@ void test_bereich1_falsche_antwort(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(759), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(730), UNITY_DISPLAY_STYLE_INT);
} }
@ -1694,7 +1688,7 @@ void test_bereich3_richtige_antwort(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(772), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(743), UNITY_DISPLAY_STYLE_INT);
} }
@ -1724,7 +1718,7 @@ void test_bereich3_falsche_antwort(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(785), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(756), UNITY_DISPLAY_STYLE_INT);
} }
@ -1754,7 +1748,7 @@ void test_bereich3_gewinner_spieler1(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(798), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(769), UNITY_DISPLAY_STYLE_INT);
} }
@ -1784,7 +1778,7 @@ void test_bereich3_gewinner_spieler2(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(811), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(782), UNITY_DISPLAY_STYLE_INT);
} }
@ -1814,7 +1808,7 @@ void test_bereich4_richtige_antwort(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(824), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(795), UNITY_DISPLAY_STYLE_INT);
} }
@ -1844,7 +1838,7 @@ void test_bereich4_falsche_antwort(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(837), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(808), UNITY_DISPLAY_STYLE_INT);
} }
@ -1874,7 +1868,7 @@ void test_bereich4_gewinner_spieler1(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(850), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(821), UNITY_DISPLAY_STYLE_INT);
} }
@ -1904,7 +1898,7 @@ void test_bereich4_gewinner_spieler2(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(863), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(834), UNITY_DISPLAY_STYLE_INT);
} }
@ -1934,6 +1928,6 @@ void test_bereich5_richtige_antwort(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(876), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(847), UNITY_DISPLAY_STYLE_INT);
} }

BIN
build/test/out/c/duellist-spielesammlung-projekt.o

BIN
build/test/out/c/test_duellist_spielesammlung_projekt.o

BIN
build/test/out/c/test_duellist_spielesammlung_projekt_runner.o

136
build/test/preprocess/files/test_duellist_spielesammlung_projekt.c

@ -14,8 +14,6 @@ void tearDown(void) {}
void test_coinflip_x_starts(void) { void test_coinflip_x_starts(void) {
@ -36,9 +34,9 @@ void test_coinflip_x_starts(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(19), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(18), UNITY_DISPLAY_STYLE_INT);
do {if ((game.currentPlayer == PLAYER_X || game.currentPlayer == PLAYER_O)) {} else {UnityFail( ((" Expected TRUE Was FALSE")), (UNITY_UINT)((UNITY_UINT)(20)));}} while(0);
do {if ((game.currentPlayer == PLAYER_X || game.currentPlayer == PLAYER_O)) {} else {UnityFail( ((" Expected TRUE Was FALSE")), (UNITY_UINT)((UNITY_UINT)(19)));}} while(0);
} }
@ -64,9 +62,9 @@ void test_coinflip_o_starts(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(31), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(30), UNITY_DISPLAY_STYLE_INT);
do {if ((game.currentPlayer == PLAYER_X || game.currentPlayer == PLAYER_O)) {} else {UnityFail( ((" Expected TRUE Was FALSE")), (UNITY_UINT)((UNITY_UINT)(32)));}} while(0);
do {if ((game.currentPlayer == PLAYER_X || game.currentPlayer == PLAYER_O)) {} else {UnityFail( ((" Expected TRUE Was FALSE")), (UNITY_UINT)((UNITY_UINT)(31)));}} while(0);
} }
@ -98,7 +96,7 @@ void test_vertical_win(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(46), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(45), UNITY_DISPLAY_STYLE_INT);
} }
@ -130,7 +128,7 @@ void test_horizontal_win(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(60), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(59), UNITY_DISPLAY_STYLE_INT);
} }
@ -160,7 +158,7 @@ void test_diagonal_win(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(73), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(72), UNITY_DISPLAY_STYLE_INT);
} }
@ -192,13 +190,13 @@ void test_valid_move_and_switch(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(87), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(86), UNITY_DISPLAY_STYLE_INT);
UnityAssertEqualNumber((UNITY_INT)((PLAYER_O)), (UNITY_INT)((game.currentPlayer)), ( UnityAssertEqualNumber((UNITY_INT)((PLAYER_O)), (UNITY_INT)((game.currentPlayer)), (
((void *)0) ((void *)0)
), (UNITY_UINT)(88), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(87), UNITY_DISPLAY_STYLE_INT);
} }
@ -232,7 +230,7 @@ void test_invalid_input(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(103), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(102), UNITY_DISPLAY_STYLE_INT);
} }
@ -264,7 +262,7 @@ void test_valid_input(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(117), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(116), UNITY_DISPLAY_STYLE_INT);
} }
@ -298,7 +296,7 @@ void test_invalid_input_negative_row(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(132), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(131), UNITY_DISPLAY_STYLE_INT);
} }
@ -330,7 +328,7 @@ void test_invalid_input_overflow_column(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(146), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(145), UNITY_DISPLAY_STYLE_INT);
} }
@ -362,7 +360,7 @@ void test_NumberOfMoves_returns_correct_number_of_moves(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(160), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(159), UNITY_DISPLAY_STYLE_INT);
} }
@ -390,7 +388,7 @@ void test_BoardFull_returns_false_when_board_is_not_full(void) {
do {if (!(boardFull)) {} else {UnityFail( ((" Expected FALSE Was TRUE")), (UNITY_UINT)((UNITY_UINT)(174)));}} while(0);
do {if (!(boardFull)) {} else {UnityFail( ((" Expected FALSE Was TRUE")), (UNITY_UINT)((UNITY_UINT)(173)));}} while(0);
} }
@ -416,7 +414,7 @@ void test_BoardFull_returns_true_when_board_is_full(void) {
do {if ((boardFull)) {} else {UnityFail( ((" Expected TRUE Was FALSE")), (UNITY_UINT)((UNITY_UINT)(187)));}} while(0);
do {if ((boardFull)) {} else {UnityFail( ((" Expected TRUE Was FALSE")), (UNITY_UINT)((UNITY_UINT)(186)));}} while(0);
} }
@ -446,7 +444,7 @@ void test_CurrentPlayer_returns_correct_player(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(200), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(199), UNITY_DISPLAY_STYLE_INT);
} }
@ -474,7 +472,7 @@ void test_FieldEmpty_returns_true_for_empty_field(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(212), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(211), UNITY_DISPLAY_STYLE_INT);
} }
@ -504,7 +502,7 @@ void test_FieldEmpty_returns_false_for_nonempty_field(void) {
((void *)0) ((void *)0)
), (UNITY_UINT)(225), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(224), UNITY_DISPLAY_STYLE_INT);
} }
@ -536,7 +534,7 @@ void test_calculate_mines_HeightWidthOne(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(239), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(238), UNITY_DISPLAY_STYLE_INT);
} }
@ -568,7 +566,7 @@ void test_calculate_mines_WidthOne(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(253), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(252), UNITY_DISPLAY_STYLE_INT);
} }
@ -600,7 +598,7 @@ void test_calculate_mines_NormalCase(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(267), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(266), UNITY_DISPLAY_STYLE_INT);
} }
@ -642,7 +640,7 @@ void test_end_check_AllUncovered_NoMines(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(286), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(285), UNITY_DISPLAY_STYLE_INT);
} }
@ -674,7 +672,7 @@ void test_create_minefield_ValidDimensions(void)
((void *)0) ((void *)0)
)) {} else {UnityFail( (((" Expected Non-NULL"))), (UNITY_UINT)((UNITY_UINT)((UNITY_UINT)(300))));}} while(0);
)) {} else {UnityFail( (((" Expected Non-NULL"))), (UNITY_UINT)((UNITY_UINT)((UNITY_UINT)(299))));}} while(0);
for (int i = 0; i < height; i++) { for (int i = 0; i < height; i++) {
@ -682,7 +680,7 @@ void test_create_minefield_ValidDimensions(void)
((void *)0) ((void *)0)
)) {} else {UnityFail( (((" Expected Non-NULL"))), (UNITY_UINT)((UNITY_UINT)((UNITY_UINT)(302))));}} while(0);
)) {} else {UnityFail( (((" Expected Non-NULL"))), (UNITY_UINT)((UNITY_UINT)((UNITY_UINT)(301))));}} while(0);
for (int j = 0; j < width; j++) { for (int j = 0; j < width; j++) {
@ -690,7 +688,7 @@ void test_create_minefield_ValidDimensions(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(304), UNITY_DISPLAY_STYLE_CHAR);
), (UNITY_UINT)(303), UNITY_DISPLAY_STYLE_CHAR);
} }
@ -736,7 +734,7 @@ void test_calculate_mines_HeightOne(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(325), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(324), UNITY_DISPLAY_STYLE_INT);
} }
@ -768,7 +766,7 @@ void test_create_minefield_NegativeDimensions(void)
((void *)0) ((void *)0)
)) {} else {UnityFail( (((" Expected NULL"))), (UNITY_UINT)((UNITY_UINT)((UNITY_UINT)(339))));}} while(0);
)) {} else {UnityFail( (((" Expected NULL"))), (UNITY_UINT)((UNITY_UINT)((UNITY_UINT)(338))));}} while(0);
} }
@ -800,7 +798,7 @@ void test_calculate_mines_HeightZero(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(353), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(352), UNITY_DISPLAY_STYLE_INT);
} }
@ -832,7 +830,7 @@ void test_calculate_mines_HeightWidthNumber(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(367), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(366), UNITY_DISPLAY_STYLE_INT);
} }
@ -864,7 +862,7 @@ void test_calculate_mines_HeightWidthAgan(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(381), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(380), UNITY_DISPLAY_STYLE_INT);
} }
@ -896,7 +894,7 @@ void test_calculate_mines_HeightWidthRoundUp(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(395), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(394), UNITY_DISPLAY_STYLE_INT);
} }
@ -928,7 +926,7 @@ void test_calculate_mines_HeightWidthNoRound(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(409), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(408), UNITY_DISPLAY_STYLE_INT);
} }
@ -960,10 +958,12 @@ void test_calculate_mines_HeightWidthFinal(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(423), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(422), UNITY_DISPLAY_STYLE_INT);
} }
void test_generateRandomNumber_withinValidRange(void) void test_generateRandomNumber_withinValidRange(void)
{ {
@ -980,7 +980,7 @@ void test_generateRandomNumber_withinValidRange(void)
do {if ((result >= 1 && result <= 100)) {} else {UnityFail( ((" Expected TRUE Was FALSE")), (UNITY_UINT)((UNITY_UINT)(459)));}} while(0);
do {if ((result >= 1 && result <= 100)) {} else {UnityFail( ((" Expected TRUE Was FALSE")), (UNITY_UINT)((UNITY_UINT)(433)));}} while(0);
} }
@ -1010,7 +1010,7 @@ void test_addition(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(472), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(446), UNITY_DISPLAY_STYLE_INT);
} }
@ -1040,7 +1040,7 @@ void test_subtraction(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(485), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(459), UNITY_DISPLAY_STYLE_INT);
} }
@ -1072,7 +1072,7 @@ void test_multiplication(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(499), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(473), UNITY_DISPLAY_STYLE_INT);
} }
@ -1102,7 +1102,7 @@ void test_division(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(512), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(486), UNITY_DISPLAY_STYLE_INT);
} }
@ -1132,7 +1132,7 @@ void test_division_byZero_returnsZero(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(525), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(499), UNITY_DISPLAY_STYLE_INT);
} }
@ -1162,7 +1162,7 @@ void test_modulo(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(538), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(512), UNITY_DISPLAY_STYLE_INT);
} }
@ -1192,7 +1192,7 @@ void test_compare_equalNumbers(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(551), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(525), UNITY_DISPLAY_STYLE_INT);
} }
@ -1222,7 +1222,7 @@ void test_compare_aLessThanB(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(564), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(538), UNITY_DISPLAY_STYLE_INT);
} }
@ -1252,7 +1252,7 @@ void test_compare_aGreaterThanB(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(577), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(551), UNITY_DISPLAY_STYLE_INT);
} }
@ -1282,7 +1282,7 @@ void test_exponentiation(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(590), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(564), UNITY_DISPLAY_STYLE_INT);
} }
@ -1312,7 +1312,7 @@ void test_exponentiation_negativeExponent(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(603), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(577), UNITY_DISPLAY_STYLE_INT);
} }
@ -1340,7 +1340,7 @@ void test_squareRoot_validNumber(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(615), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(589), UNITY_DISPLAY_STYLE_INT);
} }
@ -1368,7 +1368,7 @@ void test_squareRoot_negativeNumber(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(627), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(601), UNITY_DISPLAY_STYLE_INT);
} }
@ -1492,12 +1492,6 @@ void test_getUserAnswer_invalidInput(void)
void test_bereichauswahl_gueltige_eingabe(void) void test_bereichauswahl_gueltige_eingabe(void)
{ {
@ -1520,7 +1514,7 @@ void test_bereichauswahl_gueltige_eingabe(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(697), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(668), UNITY_DISPLAY_STYLE_INT);
} }
@ -1548,7 +1542,7 @@ void test_bereichauswahl_ungueltige_eingabe(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(709), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(680), UNITY_DISPLAY_STYLE_INT);
} }
@ -1576,7 +1570,7 @@ void test_bereichfalsch_gueltige_eingabe(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(721), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(692), UNITY_DISPLAY_STYLE_INT);
} }
@ -1604,7 +1598,7 @@ void test_bereichfalsch_ungueltige_eingabe(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(733), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(704), UNITY_DISPLAY_STYLE_INT);
} }
@ -1634,7 +1628,7 @@ void test_bereich1_richtige_antwort(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(746), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(717), UNITY_DISPLAY_STYLE_INT);
} }
@ -1664,7 +1658,7 @@ void test_bereich1_falsche_antwort(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(759), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(730), UNITY_DISPLAY_STYLE_INT);
} }
@ -1694,7 +1688,7 @@ void test_bereich3_richtige_antwort(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(772), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(743), UNITY_DISPLAY_STYLE_INT);
} }
@ -1724,7 +1718,7 @@ void test_bereich3_falsche_antwort(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(785), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(756), UNITY_DISPLAY_STYLE_INT);
} }
@ -1754,7 +1748,7 @@ void test_bereich3_gewinner_spieler1(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(798), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(769), UNITY_DISPLAY_STYLE_INT);
} }
@ -1784,7 +1778,7 @@ void test_bereich3_gewinner_spieler2(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(811), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(782), UNITY_DISPLAY_STYLE_INT);
} }
@ -1814,7 +1808,7 @@ void test_bereich4_richtige_antwort(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(824), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(795), UNITY_DISPLAY_STYLE_INT);
} }
@ -1844,7 +1838,7 @@ void test_bereich4_falsche_antwort(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(837), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(808), UNITY_DISPLAY_STYLE_INT);
} }
@ -1874,7 +1868,7 @@ void test_bereich4_gewinner_spieler1(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(850), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(821), UNITY_DISPLAY_STYLE_INT);
} }
@ -1904,7 +1898,7 @@ void test_bereich4_gewinner_spieler2(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(863), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(834), UNITY_DISPLAY_STYLE_INT);
} }
@ -1934,6 +1928,6 @@ void test_bereich5_richtige_antwort(void)
((void *)0) ((void *)0)
), (UNITY_UINT)(876), UNITY_DISPLAY_STYLE_INT);
), (UNITY_UINT)(847), UNITY_DISPLAY_STYLE_INT);
} }

126
build/test/runners/test_duellist_spielesammlung_projekt_runner.c

@ -137,69 +137,69 @@ static void run_test(UnityTestFunction func, const char* name, UNITY_LINE_TYPE l
int main(void) int main(void)
{ {
UnityBegin("test_duellist_spielesammlung_projekt.c"); UnityBegin("test_duellist_spielesammlung_projekt.c");
run_test(test_coinflip_x_starts, "test_coinflip_x_starts", 11);
run_test(test_coinflip_o_starts, "test_coinflip_o_starts", 23);
run_test(test_vertical_win, "test_vertical_win", 35);
run_test(test_horizontal_win, "test_horizontal_win", 49);
run_test(test_diagonal_win, "test_diagonal_win", 62);
run_test(test_valid_move_and_switch, "test_valid_move_and_switch", 76);
run_test(test_invalid_input, "test_invalid_input", 92);
run_test(test_valid_input, "test_valid_input", 106);
run_test(test_invalid_input_negative_row, "test_invalid_input_negative_row", 121);
run_test(test_invalid_input_overflow_column, "test_invalid_input_overflow_column", 135);
run_test(test_NumberOfMoves_returns_correct_number_of_moves, "test_NumberOfMoves_returns_correct_number_of_moves", 149);
run_test(test_BoardFull_returns_false_when_board_is_not_full, "test_BoardFull_returns_false_when_board_is_not_full", 163);
run_test(test_BoardFull_returns_true_when_board_is_full, "test_BoardFull_returns_true_when_board_is_full", 176);
run_test(test_CurrentPlayer_returns_correct_player, "test_CurrentPlayer_returns_correct_player", 189);
run_test(test_FieldEmpty_returns_true_for_empty_field, "test_FieldEmpty_returns_true_for_empty_field", 202);
run_test(test_FieldEmpty_returns_false_for_nonempty_field, "test_FieldEmpty_returns_false_for_nonempty_field", 215);
run_test(test_calculate_mines_HeightWidthOne, "test_calculate_mines_HeightWidthOne", 228);
run_test(test_calculate_mines_WidthOne, "test_calculate_mines_WidthOne", 242);
run_test(test_calculate_mines_NormalCase, "test_calculate_mines_NormalCase", 256);
run_test(test_end_check_AllUncovered_NoMines, "test_end_check_AllUncovered_NoMines", 270);
run_test(test_create_minefield_ValidDimensions, "test_create_minefield_ValidDimensions", 289);
run_test(test_calculate_mines_HeightOne, "test_calculate_mines_HeightOne", 314);
run_test(test_create_minefield_NegativeDimensions, "test_create_minefield_NegativeDimensions", 328);
run_test(test_calculate_mines_HeightZero, "test_calculate_mines_HeightZero", 342);
run_test(test_calculate_mines_HeightWidthNumber, "test_calculate_mines_HeightWidthNumber", 356);
run_test(test_calculate_mines_HeightWidthAgan, "test_calculate_mines_HeightWidthAgan", 370);
run_test(test_calculate_mines_HeightWidthRoundUp, "test_calculate_mines_HeightWidthRoundUp", 384);
run_test(test_calculate_mines_HeightWidthNoRound, "test_calculate_mines_HeightWidthNoRound", 398);
run_test(test_calculate_mines_HeightWidthFinal, "test_calculate_mines_HeightWidthFinal", 412);
run_test(test_generateRandomNumber_withinValidRange, "test_generateRandomNumber_withinValidRange", 451);
run_test(test_addition, "test_addition", 462);
run_test(test_subtraction, "test_subtraction", 475);
run_test(test_multiplication, "test_multiplication", 489);
run_test(test_division, "test_division", 502);
run_test(test_division_byZero_returnsZero, "test_division_byZero_returnsZero", 515);
run_test(test_modulo, "test_modulo", 528);
run_test(test_compare_equalNumbers, "test_compare_equalNumbers", 541);
run_test(test_compare_aLessThanB, "test_compare_aLessThanB", 554);
run_test(test_compare_aGreaterThanB, "test_compare_aGreaterThanB", 567);
run_test(test_exponentiation, "test_exponentiation", 580);
run_test(test_exponentiation_negativeExponent, "test_exponentiation_negativeExponent", 593);
run_test(test_squareRoot_validNumber, "test_squareRoot_validNumber", 606);
run_test(test_squareRoot_negativeNumber, "test_squareRoot_negativeNumber", 618);
run_test(test_displayResult_correctResult, "test_displayResult_correctResult", 630);
run_test(test_displayMenu_validMenu, "test_displayMenu_validMenu", 643);
run_test(test_getUserChoice_invalidInput, "test_getUserChoice_invalidInput", 653);
run_test(test_playGame_correctResult, "test_playGame_correctResult", 665);
run_test(test_getUserAnswer_invalidInput, "test_getUserAnswer_invalidInput", 673);
run_test(test_bereichauswahl_gueltige_eingabe, "test_bereichauswahl_gueltige_eingabe", 688);
run_test(test_bereichauswahl_ungueltige_eingabe, "test_bereichauswahl_ungueltige_eingabe", 700);
run_test(test_bereichfalsch_gueltige_eingabe, "test_bereichfalsch_gueltige_eingabe", 712);
run_test(test_bereichfalsch_ungueltige_eingabe, "test_bereichfalsch_ungueltige_eingabe", 724);
run_test(test_bereich1_richtige_antwort, "test_bereich1_richtige_antwort", 736);
run_test(test_bereich1_falsche_antwort, "test_bereich1_falsche_antwort", 749);
run_test(test_bereich3_richtige_antwort, "test_bereich3_richtige_antwort", 762);
run_test(test_bereich3_falsche_antwort, "test_bereich3_falsche_antwort", 775);
run_test(test_bereich3_gewinner_spieler1, "test_bereich3_gewinner_spieler1", 788);
run_test(test_bereich3_gewinner_spieler2, "test_bereich3_gewinner_spieler2", 801);
run_test(test_bereich4_richtige_antwort, "test_bereich4_richtige_antwort", 814);
run_test(test_bereich4_falsche_antwort, "test_bereich4_falsche_antwort", 827);
run_test(test_bereich4_gewinner_spieler1, "test_bereich4_gewinner_spieler1", 840);
run_test(test_bereich4_gewinner_spieler2, "test_bereich4_gewinner_spieler2", 853);
run_test(test_bereich5_richtige_antwort, "test_bereich5_richtige_antwort", 866);
run_test(test_coinflip_x_starts, "test_coinflip_x_starts", 10);
run_test(test_coinflip_o_starts, "test_coinflip_o_starts", 22);
run_test(test_vertical_win, "test_vertical_win", 34);
run_test(test_horizontal_win, "test_horizontal_win", 48);
run_test(test_diagonal_win, "test_diagonal_win", 61);
run_test(test_valid_move_and_switch, "test_valid_move_and_switch", 75);
run_test(test_invalid_input, "test_invalid_input", 91);
run_test(test_valid_input, "test_valid_input", 105);
run_test(test_invalid_input_negative_row, "test_invalid_input_negative_row", 120);
run_test(test_invalid_input_overflow_column, "test_invalid_input_overflow_column", 134);
run_test(test_NumberOfMoves_returns_correct_number_of_moves, "test_NumberOfMoves_returns_correct_number_of_moves", 148);
run_test(test_BoardFull_returns_false_when_board_is_not_full, "test_BoardFull_returns_false_when_board_is_not_full", 162);
run_test(test_BoardFull_returns_true_when_board_is_full, "test_BoardFull_returns_true_when_board_is_full", 175);
run_test(test_CurrentPlayer_returns_correct_player, "test_CurrentPlayer_returns_correct_player", 188);
run_test(test_FieldEmpty_returns_true_for_empty_field, "test_FieldEmpty_returns_true_for_empty_field", 201);
run_test(test_FieldEmpty_returns_false_for_nonempty_field, "test_FieldEmpty_returns_false_for_nonempty_field", 214);
run_test(test_calculate_mines_HeightWidthOne, "test_calculate_mines_HeightWidthOne", 227);
run_test(test_calculate_mines_WidthOne, "test_calculate_mines_WidthOne", 241);
run_test(test_calculate_mines_NormalCase, "test_calculate_mines_NormalCase", 255);
run_test(test_end_check_AllUncovered_NoMines, "test_end_check_AllUncovered_NoMines", 269);
run_test(test_create_minefield_ValidDimensions, "test_create_minefield_ValidDimensions", 288);
run_test(test_calculate_mines_HeightOne, "test_calculate_mines_HeightOne", 313);
run_test(test_create_minefield_NegativeDimensions, "test_create_minefield_NegativeDimensions", 327);
run_test(test_calculate_mines_HeightZero, "test_calculate_mines_HeightZero", 341);
run_test(test_calculate_mines_HeightWidthNumber, "test_calculate_mines_HeightWidthNumber", 355);
run_test(test_calculate_mines_HeightWidthAgan, "test_calculate_mines_HeightWidthAgan", 369);
run_test(test_calculate_mines_HeightWidthRoundUp, "test_calculate_mines_HeightWidthRoundUp", 383);
run_test(test_calculate_mines_HeightWidthNoRound, "test_calculate_mines_HeightWidthNoRound", 397);
run_test(test_calculate_mines_HeightWidthFinal, "test_calculate_mines_HeightWidthFinal", 411);
run_test(test_generateRandomNumber_withinValidRange, "test_generateRandomNumber_withinValidRange", 425);
run_test(test_addition, "test_addition", 436);
run_test(test_subtraction, "test_subtraction", 449);
run_test(test_multiplication, "test_multiplication", 463);
run_test(test_division, "test_division", 476);
run_test(test_division_byZero_returnsZero, "test_division_byZero_returnsZero", 489);
run_test(test_modulo, "test_modulo", 502);
run_test(test_compare_equalNumbers, "test_compare_equalNumbers", 515);
run_test(test_compare_aLessThanB, "test_compare_aLessThanB", 528);
run_test(test_compare_aGreaterThanB, "test_compare_aGreaterThanB", 541);
run_test(test_exponentiation, "test_exponentiation", 554);
run_test(test_exponentiation_negativeExponent, "test_exponentiation_negativeExponent", 567);
run_test(test_squareRoot_validNumber, "test_squareRoot_validNumber", 580);
run_test(test_squareRoot_negativeNumber, "test_squareRoot_negativeNumber", 592);
run_test(test_displayResult_correctResult, "test_displayResult_correctResult", 604);
run_test(test_displayMenu_validMenu, "test_displayMenu_validMenu", 617);
run_test(test_getUserChoice_invalidInput, "test_getUserChoice_invalidInput", 627);
run_test(test_playGame_correctResult, "test_playGame_correctResult", 639);
run_test(test_getUserAnswer_invalidInput, "test_getUserAnswer_invalidInput", 647);
run_test(test_bereichauswahl_gueltige_eingabe, "test_bereichauswahl_gueltige_eingabe", 659);
run_test(test_bereichauswahl_ungueltige_eingabe, "test_bereichauswahl_ungueltige_eingabe", 671);
run_test(test_bereichfalsch_gueltige_eingabe, "test_bereichfalsch_gueltige_eingabe", 683);
run_test(test_bereichfalsch_ungueltige_eingabe, "test_bereichfalsch_ungueltige_eingabe", 695);
run_test(test_bereich1_richtige_antwort, "test_bereich1_richtige_antwort", 707);
run_test(test_bereich1_falsche_antwort, "test_bereich1_falsche_antwort", 720);
run_test(test_bereich3_richtige_antwort, "test_bereich3_richtige_antwort", 733);
run_test(test_bereich3_falsche_antwort, "test_bereich3_falsche_antwort", 746);
run_test(test_bereich3_gewinner_spieler1, "test_bereich3_gewinner_spieler1", 759);
run_test(test_bereich3_gewinner_spieler2, "test_bereich3_gewinner_spieler2", 772);
run_test(test_bereich4_richtige_antwort, "test_bereich4_richtige_antwort", 785);
run_test(test_bereich4_falsche_antwort, "test_bereich4_falsche_antwort", 798);
run_test(test_bereich4_gewinner_spieler1, "test_bereich4_gewinner_spieler1", 811);
run_test(test_bereich4_gewinner_spieler2, "test_bereich4_gewinner_spieler2", 824);
run_test(test_bereich5_richtige_antwort, "test_bereich5_richtige_antwort", 837);
return UnityEnd(); return UnityEnd();
} }

1
src/main/duellist-spielesammlung-projekt.c

@ -1,4 +1,5 @@
#include <stdio.h> #include <stdio.h>
#include <math.h>
#include <stdlib.h> #include <stdlib.h>
#include <time.h> #include <time.h>
#include "duellist-spielesammlung-projekt.h" #include "duellist-spielesammlung-projekt.h"

Loading…
Cancel
Save