mirror of
https://github.com/znc/znc.git
synced 2026-03-28 17:42:41 +01:00
[CString.StripControls] Srip bg colours when we reset fg
This commit is contained in:
@@ -263,3 +263,11 @@ TEST(StringTest, Contains) {
|
||||
EXPECT_FALSE(
|
||||
CString("Hello, I'm Bob").Contains("i'm bob", CString::CaseSensitive));
|
||||
}
|
||||
|
||||
TEST(StringTest, StripControls) {
|
||||
// Strips reset colours
|
||||
EXPECT_EQ(CString("\x03test").StripControls(), "test");
|
||||
|
||||
// Strips reset foreground and set new background colour
|
||||
EXPECT_EQ(CString("\x03,03test").StripControls(), "test");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user