Browse Source

added test for converting small int to hex string

remotes/origin/conversionOfNumbers
Laurin 11 months ago
parent
commit
9fbe4606e1
  1. 13
      test/conversionOfNumbers/test_conversionOfNumbers.c

13
test/conversionOfNumbers/test_conversionOfNumbers.c

@ -114,4 +114,17 @@ void test_convertBinaryStr1001ToInt9(){
//assert //assert
TEST_ASSERT_EQUAL_UINT(expected, result); TEST_ASSERT_EQUAL_UINT(expected, result);
}
void test_convert3ToHexStr3(){
//arrange
char* result;
char expected[] = "3";
//act
result = convertIntToHex(3);
//assert
TEST_ASSERT_EQUAL_STRING(expected, result);
free(result);
} }
Loading…
Cancel
Save