]> jfr.im git - irc/evilnet/znc.git/commitdiff
Test #1715
authorAlexey Sokolov <redacted>
Mon, 20 Apr 2020 19:51:07 +0000 (20:51 +0100)
committerAlexey Sokolov <redacted>
Mon, 20 Apr 2020 19:51:07 +0000 (20:51 +0100)
test/StringTest.cpp

index aef7881da37b0b015b095c3df930664e6f843489..7c2efec2ccddca94513a66d6a668910c69783df7 100644 (file)
@@ -53,6 +53,8 @@ TEST_F(EscapeTest, Test) {
     testString("&<>",    "%26%3C%3E", "&amp;&lt;&gt;", "&<>",       "&<>");
     testString(" ;",     "+%3B",      " ;",            " ;",        "\\s\\:");
     // clang-format on
+    EXPECT_EQ(CString("a&lt.b&gt;c").Escape_n(CString::EHTML, CString::EASCII),
+              "a&lt.b>c");
 }
 
 TEST(StringTest, Bool) {
@@ -199,8 +201,8 @@ TEST(StringTest, Equals) {
 
 TEST(StringTest, Find) {
     EXPECT_EQ(CString("Hello, I'm Bob").Find("Hello"), 0u);
-    EXPECT_EQ(
-        CString("Hello, I'm Bob").Find("Hello", CString::CaseInsensitive), 0u);
+    EXPECT_EQ(CString("Hello, I'm Bob").Find("Hello", CString::CaseInsensitive),
+              0u);
     EXPECT_EQ(CString("Hello, I'm Bob").Find("Hello", CString::CaseSensitive),
               0u);