| OLD | NEW |
| (Empty) | |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #include "wtf/text/TextCodecICU.h" |
| 6 |
| 7 #include "testing/gtest/include/gtest/gtest.h" |
| 8 #include "wtf/text/CharacterNames.h" |
| 9 |
| 10 namespace WTF { |
| 11 |
| 12 TEST(TextCodecICUTest, IgnorableCodePoint) |
| 13 { |
| 14 TextEncoding iso2022jp("iso-2022-jp"); |
| 15 std::unique_ptr<TextCodec> codec = TextCodecICU::create(iso2022jp, nullptr); |
| 16 Vector<UChar> source; |
| 17 source.append('a'); |
| 18 source.append(zeroWidthJoinerCharacter); |
| 19 CString encoded = codec->encode(source.data(), source.size(), EntitiesForUne
ncodables); |
| 20 EXPECT_STREQ("a‍", encoded.data()); |
| 21 } |
| 22 |
| 23 } |
| OLD | NEW |