From 4e72b760f002ecebad718f162cbcdf34ec07f4c5 Mon Sep 17 00:00:00 2001 From: fdai7472 Date: Mon, 29 Jan 2024 18:33:31 +0100 Subject: [PATCH] Tests, falls 3 Reihen gewinnen --- src/test/c/Stefan/test_slot_machine.c | 28 +++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/src/test/c/Stefan/test_slot_machine.c b/src/test/c/Stefan/test_slot_machine.c index 3739660..f2a17c9 100644 --- a/src/test/c/Stefan/test_slot_machine.c +++ b/src/test/c/Stefan/test_slot_machine.c @@ -194,3 +194,31 @@ void test_3_C_3_D_won_bet_equals_10() { //assert TEST_ASSERT_EQUAL_INT(expectedResult, actualResult); } + +void test_9_A_won_bet_equals_10() { + + //arrange + char testSymbols[] = {"AAAAAAAAA"}; + + int expectedResult = 90; + + //act + int actualResult = getWinnings(testSymbols, 10); + + //assert + TEST_ASSERT_EQUAL_INT(expectedResult, actualResult); +} + +void test_3_B_3_C_3_D_won_bet_equals_10() { + + //arrange + char testSymbols[] = {"BBBCCCDDD"}; + + int expectedResult = 350; + + //act + int actualResult = getWinnings(testSymbols, 10); + + //assert + TEST_ASSERT_EQUAL_INT(expectedResult, actualResult); +} \ No newline at end of file