summaryrefslogtreecommitdiff
path: root/core/fxcrt/bytestring_unittest.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'core/fxcrt/bytestring_unittest.cpp')
-rw-r--r--core/fxcrt/bytestring_unittest.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/core/fxcrt/bytestring_unittest.cpp b/core/fxcrt/bytestring_unittest.cpp
index 7095a1b799..abc3648f18 100644
--- a/core/fxcrt/bytestring_unittest.cpp
+++ b/core/fxcrt/bytestring_unittest.cpp
@@ -390,6 +390,13 @@ TEST(ByteString, OperatorNE) {
EXPECT_TRUE(c_string3 != byte_string);
}
+TEST(ByteString, OperatorPlus) {
+ EXPECT_EQ("I like dogs", "I like " + ByteString("dogs"));
+ EXPECT_EQ("Dogs like me", ByteString("Dogs") + " like me");
+ EXPECT_EQ("Oh no, error number 42",
+ "Oh no, error number " + ByteString::Format("%d", 42));
+}
+
TEST(ByteString, Concat) {
ByteString fred;
fred.Concat("FRED", 4);