summaryrefslogtreecommitdiffstats
path: root/base/string_util_unittest.cc
diff options
context:
space:
mode:
authorjschuh@chromium.org <jschuh@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-01-16 16:40:38 +0000
committerjschuh@chromium.org <jschuh@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-01-16 16:40:38 +0000
commit548a6c0f30c3dcf374cc06be48f02a06da5c1d19 (patch)
tree57a3406e6d51b44774b9fa37cde1810a1d76a47c /base/string_util_unittest.cc
parentb78e6049b83a6a221b6c7b47c229b337e3abce43 (diff)
downloadchromium_src-548a6c0f30c3dcf374cc06be48f02a06da5c1d19.zip
chromium_src-548a6c0f30c3dcf374cc06be48f02a06da5c1d19.tar.gz
chromium_src-548a6c0f30c3dcf374cc06be48f02a06da5c1d19.tar.bz2
Changes are:
* base::IsValidCodepoint() now returns false on non-character code points. * base::IsStringUTF8() now uses ICU library (removed old Mozilla implementation). * Removed base::IsStringWideUTF8() (was unused and confusing) * file_util::ReplaceIllegalCharactersInPath() now treats Unicode replacement character (U+FFFD) as invalid. * Associated unit tests updated. BUG=2759 BUG=30662 TEST=base_unittests --gtest_filter=StringUtilTest.IsStringUTF8 TEST=base_unittests --gtest_filter=UTFStringConversionsTest.* TEST=base_unittests --gtest_filter=FileUtilICUTestReplaceIllegalCharactersInPathTest Review URL: http://codereview.chromium.org/548017 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@36459 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/string_util_unittest.cc')
-rw-r--r--base/string_util_unittest.cc5
1 files changed, 0 insertions, 5 deletions
diff --git a/base/string_util_unittest.cc b/base/string_util_unittest.cc
index 9d848a4..6f366a6 100644
--- a/base/string_util_unittest.cc
+++ b/base/string_util_unittest.cc
@@ -225,13 +225,8 @@ TEST(StringUtilTest, IsStringUTF8) {
EXPECT_FALSE(IsStringUTF8("\xef\xbf\xbe")); // U+FFFE)
EXPECT_FALSE(IsStringUTF8("\xf0\x8f\xbf\xbe")); // U+1FFFE
EXPECT_FALSE(IsStringUTF8("\xf3\xbf\xbf\xbf")); // U+10FFFF
-
- // This should also be false, but currently we pass them through.
- // Disable them for now.
-#if 0
EXPECT_FALSE(IsStringUTF8("\xef\xb7\x90")); // U+FDD0
EXPECT_FALSE(IsStringUTF8("\xef\xb7\xaf")); // U+FDEF
-#endif
// Strings in legacy encodings. We can certainly make up strings
// in a legacy encoding that are valid in UTF-8, but in real data,