chore: String toHex should return a string not do inplace conversion

This commit is contained in:
sithlord48
2025-01-25 07:54:33 -05:00
committed by Nick Bolton
parent ac54a97a3f
commit 9b1489384c
5 changed files with 7 additions and 11 deletions

View File

@ -56,12 +56,7 @@ TEST(StringTests, sprintf_formatWithArgument_formatedString)
TEST(StringTests, toHex_plaintext_hexString)
{
std::string subject = "foobar";
int width = 2;
string::toHex(subject, width);
EXPECT_EQ("666f6f626172", subject);
EXPECT_EQ("666f6f626172", string::toHex("foobar", 2));
}
TEST(StringTests, uppercase_lowercaseInput_uppercaseOutput)