Browse Source

Test Division durch 0

remotes/origin/erwin
fdai7820 11 months ago
parent
commit
3cbc462e7d
  1. 11
      src/test/test_duellist_spielesammlung_projekt.c

11
src/test/test_duellist_spielesammlung_projekt.c

@ -512,7 +512,18 @@ void test_division(void)
TEST_ASSERT_EQUAL_INT(5, result);
}
void test_division_byZero_returnsZero(void)
{
/* arrange */
int num1 = 8;
int num2 = 0;
/* act */
int result = division(num1, num2);
/* assert */
TEST_ASSERT_EQUAL_INT(0, result);
}

Loading…
Cancel
Save