Browse Source

added test for getllu with min and max

remotes/origin/userinput
TheUltimateOptimist 11 months ago
parent
commit
4fbe2042a8
  1. 8
      test/test_userinput.c

8
test/test_userinput.c

@ -69,4 +69,12 @@ void test_getlu_WithMinAndMax(void) {
char *input[] = {"sdf", "-400", "10000000000000", "11001100", NULL}; char *input[] = {"sdf", "-400", "10000000000000", "11001100", NULL};
fakeInput = input; fakeInput = input;
TEST_ASSERT_EQUAL_UINT64(11001100, getlu("", &min, &max)); TEST_ASSERT_EQUAL_UINT64(11001100, getlu("", &min, &max));
}
void test_getllu_WithMinAndMax(void) {
unsigned long long min = 100;
unsigned long long max = 100000000;
char *input[] = {"sdf", "-400", "10000000000000", "11001100", NULL};
fakeInput = input;
TEST_ASSERT_EQUAL_UINT64(11001100, getllu("", &min, &max));
} }
Loading…
Cancel
Save