[Bug Fix] Remove StringUtilTest::EscapeStringMemoryTest (#2310)

This was testing the old std::string EscapeString(const char *src,
size_t sz) which was removed since it's not used anywhere else.
This commit is contained in:
Michael Cook (mackal) 2022-07-14 20:47:58 -04:00 committed by GitHub
parent ffe4d528e7
commit 9488ee1e8c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -28,7 +28,6 @@ public:
StringUtilTest() {
TEST_ADD(StringUtilTest::StringFormatTest);
TEST_ADD(StringUtilTest::EscapeStringTest);
TEST_ADD(StringUtilTest::EscapeStringMemoryTest);
TEST_ADD(StringUtilTest::SearchDeliminatedStringTest);
TEST_ADD(StringUtilTest::SplitStringTest);
}
@ -66,23 +65,6 @@ public:
TEST_ASSERT(s.compare("abc\\x00\\n\\r\\\\\\'\\\"\\x1a") == 0);
}
void EscapeStringMemoryTest() {
char t[10] = { 0 };
t[0] = 'a';
t[1] = 'b';
t[2] = 'c';
t[3] = '\x00';
t[4] = '\n';
t[5] = '\r';
t[6] = '\\';
t[7] = '\'';
t[8] = '\"';
t[9] = '\x1a';
auto s = Strings::Escape(t, 10);
TEST_ASSERT(s.compare("abc\\x00\\n\\r\\\\\\'\\\"\\x1a") == 0);
}
void SearchDeliminatedStringTest() {
std::string h =
"befallen,charasis,dalnir,frontiermtns,gukbottom,iceclad,lakeofillomen,northkarana,qey2hh1,soldunga,southro,wakening,podisease,velketor,akheva,riwwi,bothunder,poair";