Index: ui/base/l10n/l10n_util_unittest.cc |
diff --git a/ui/base/l10n/l10n_util_unittest.cc b/ui/base/l10n/l10n_util_unittest.cc |
index dda3efe3094512861ee63f75be2c46936d912eb0..778476c72e88dee5d5f82ea5f89cd08a33a9cc51 100644 |
--- a/ui/base/l10n/l10n_util_unittest.cc |
+++ b/ui/base/l10n/l10n_util_unittest.cc |
@@ -65,36 +65,6 @@ TEST_F(L10nUtilTest, DISABLED_GetString) { |
} |
#endif // defined(OS_WIN) |
-TEST_F(L10nUtilTest, TruncateString) { |
- string16 string = ASCIIToUTF16("foooooey bxxxar baz"); |
- |
- // Make sure it doesn't modify the string if length > string length. |
- EXPECT_EQ(string, l10n_util::TruncateString(string, 100)); |
- |
- // Test no characters. |
- EXPECT_EQ(L"", UTF16ToWide(l10n_util::TruncateString(string, 0))); |
- |
- // Test 1 character. |
- EXPECT_EQ(L"\x2026", UTF16ToWide(l10n_util::TruncateString(string, 1))); |
- |
- // Test adds ... at right spot when there is enough room to break at a |
- // word boundary. |
- EXPECT_EQ(L"foooooey\x2026", |
- UTF16ToWide(l10n_util::TruncateString(string, 14))); |
- |
- // Test adds ... at right spot when there is not enough space in first word. |
- EXPECT_EQ(L"f\x2026", UTF16ToWide(l10n_util::TruncateString(string, 2))); |
- |
- // Test adds ... at right spot when there is not enough room to break at a |
- // word boundary. |
- EXPECT_EQ(L"foooooey\x2026", |
- UTF16ToWide(l10n_util::TruncateString(string, 11))); |
- |
- // Test completely truncates string if break is on initial whitespace. |
- EXPECT_EQ(L"\x2026", |
- UTF16ToWide(l10n_util::TruncateString(ASCIIToUTF16(" "), 2))); |
-} |
- |
void SetICUDefaultLocale(const std::string& locale_string) { |
icu::Locale locale(locale_string.c_str()); |
UErrorCode error_code = U_ZERO_ERROR; |