| Index: third_party/WebKit/Source/wtf/text/StringViewTest.cpp
|
| diff --git a/third_party/WebKit/Source/wtf/text/StringViewTest.cpp b/third_party/WebKit/Source/wtf/text/StringViewTest.cpp
|
| index 6c56f43feda9c01e3bf84674755f5071f3fe1d79..05c781d3dc6db475059dbe366054506ae323453a 100644
|
| --- a/third_party/WebKit/Source/wtf/text/StringViewTest.cpp
|
| +++ b/third_party/WebKit/Source/wtf/text/StringViewTest.cpp
|
| @@ -323,6 +323,15 @@ TEST(StringViewTest, ToString)
|
| // NOTE: All the construction tests also check toString().
|
| }
|
|
|
| +TEST(StringViewTest, ToAtomicString)
|
| +{
|
| + EXPECT_EQ(AtomicString(), nullAtom);
|
| + EXPECT_EQ(AtomicString(""), emptyAtom);
|
| + EXPECT_EQ(AtomicString("12"), StringView(kChars8, 2).toAtomicString());
|
| + // AtomicString will convert to 8bit if possible when creating the string.
|
| + EXPECT_EQ(AtomicString("12"), StringView(kChars16, 2).toAtomicString());
|
| +}
|
| +
|
| TEST(StringViewTest, NullString)
|
| {
|
| EXPECT_TRUE(StringView().isNull());
|
|
|