diff options
Diffstat (limited to 'base/sys_string_conversions_win_unittest.cc')
-rw-r--r-- | base/sys_string_conversions_win_unittest.cc | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/base/sys_string_conversions_win_unittest.cc b/base/sys_string_conversions_win_unittest.cc index 3a5b9ad7..70c8592 100644 --- a/base/sys_string_conversions_win_unittest.cc +++ b/base/sys_string_conversions_win_unittest.cc @@ -43,7 +43,10 @@ TEST(SysStringsWin, SysWideToUTF8) { // Error case. When Windows finds a UTF-16 character going off the end of // a string, it just converts that literal value to UTF-8, even though this // is invalid. - EXPECT_EQ("\xE4\xBD\xA0\xED\xA0\x80zyxw", SysWideToUTF8(L"\x4f60\xd800zyxw")); + // + // This is what XP does, but Vista has different behavior, so we don't bother + // verifying it: + //EXPECT_EQ("\xE4\xBD\xA0\xED\xA0\x80zyxw", SysWideToUTF8(L"\x4f60\xd800zyxw")); // Test embedded NULLs. std::wstring wide_null(L"a"); @@ -65,7 +68,10 @@ TEST(SysStringsWin, SysUTF8ToWide) { // Error case. When Windows finds an invalid UTF-8 character, it just skips // it. This seems weird because it's inconsistent with the reverse conversion. - EXPECT_EQ(L"\x4f60zyxw", SysUTF8ToWide("\xe4\xbd\xa0\xe5\xa5zyxw")); + // + // This is what XP does, but Vista has different behavior, so we don't bother + // verifying it: + //EXPECT_EQ(L"\x4f60zyxw", SysUTF8ToWide("\xe4\xbd\xa0\xe5\xa5zyxw")); // Test embedded NULLs. std::string utf8_null("a"); |