summaryrefslogtreecommitdiff
path: root/src/utils/stringutils_unittest.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/utils/stringutils_unittest.cc')
-rw-r--r--src/utils/stringutils_unittest.cc14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/utils/stringutils_unittest.cc b/src/utils/stringutils_unittest.cc
index d3d274597..75f4f2f35 100644
--- a/src/utils/stringutils_unittest.cc
+++ b/src/utils/stringutils_unittest.cc
@@ -372,6 +372,20 @@ TEST(stringuntils, combineDye2)
combineDye2("test.xml|#43413d,59544f,7a706c;#123456", "W;B"));
}
+TEST(stringuntils, combineDye3)
+{
+ EXPECT_EQ("", combineDye3("", ""));
+ EXPECT_EQ("test", combineDye3("test", ""));
+ EXPECT_EQ("", combineDye3("", "line"));
+ EXPECT_EQ("test.xml|123", combineDye3("test.xml", "123"));
+ EXPECT_EQ("test.xml|#43413d,59544f,7a706c",
+ combineDye3("test.xml|#43413d,59544f,7a706c", ""));
+ EXPECT_EQ("test.xml|#43413d,59544f,7a706c:W;",
+ combineDye3("test.xml|#43413d,59544f,7a706c", "W"));
+ EXPECT_EQ("test.xml|#43413d,59544f,7a706c:W;#123456:B;",
+ combineDye3("test.xml|#43413d,59544f,7a706c;#123456", "W;B"));
+}
+
TEST(stringuntils, packList1)
{
std::list <std::string> list;