Implement ICU support for uppercasing, with tests.

This commit is contained in:
Fusxfaranto authored and Aaron van Geffen committed 2018-05-22 17:37:07 +02:00
1 parent f29b42cc26
commit a91dd6a356
3 files changed
+31 -6

No files matched your search

+15
View File
@@ -114,3 +114,18 @@ TEST_F(StringTest, Convert_Empty)
}
#endif
///////////////////////////////////////////////////////////////////////////////
// Tests for String::ToUpper
///////////////////////////////////////////////////////////////////////////////
TEST_F(StringTest, ToUpper_Basic)
{
auto actual = String::ToUpper("test TEST tEsT 1234");
ASSERT_STREQ(actual.c_str(), "TEST TEST TEST 1234");
}
TEST_F(StringTest, ToUpper_Unicode)
{
auto actual = String::ToUpper("éœǘξдȿ𞥃ꜳᲁ ÉŒǗΞДⱾ𞤡ꜲД 語");
ASSERT_STREQ(actual.c_str(), "ÉŒǗΞДⱾ𞤡ꜲД ÉŒǗΞДⱾ𞤡ꜲД 語");
}