Chromium Code Reviews| Index: third_party/WebKit/Source/core/dom/DocumentTest.cpp |
| diff --git a/third_party/WebKit/Source/core/dom/DocumentTest.cpp b/third_party/WebKit/Source/core/dom/DocumentTest.cpp |
| index 5aa5712de737645acf67a4b34b684311e9ad3aff..b9f58385debb2a52ea91aa8beac730895e6a3874 100644 |
| --- a/third_party/WebKit/Source/core/dom/DocumentTest.cpp |
| +++ b/third_party/WebKit/Source/core/dom/DocumentTest.cpp |
| @@ -590,4 +590,25 @@ TEST_F(DocumentTest, SynchronousMutationNotifierUpdateCharacterData) { |
| EXPECT_EQ(observer.updatedCharacterDataRecords()[3]->m_newLength, 3u); |
| } |
| +// This tests that meta-theme-color can be found correctly |
| +TEST_F(DocumentTest, ThemeColor) { |
| + { |
| + setHtmlInnerHTML( |
| + "<meta name=\"theme-color\" content=\"#00ff00\">" |
| + "<body>" |
| + "Theme color should be bright green."); |
|
tkent
2016/12/09 09:20:53
This sentence isn't necessary.
lpy
2016/12/09 17:53:37
Done.
|
| + EXPECT_EQ(Color(0, 255, 0), document().themeColor()) |
| + << "Theme color should be bright green."; |
| + } |
| + |
| + { |
| + setHtmlInnerHTML( |
| + "<body>" |
| + "<meta name=\"theme-color\" content=\"#00ff00\">" |
| + "Theme color should be bright green."); |
|
tkent
2016/12/09 09:20:53
This sentence isn't necessary.
lpy
2016/12/09 17:53:37
Done.
|
| + EXPECT_EQ(Color(0, 255, 0), document().themeColor()) |
| + << "Theme color should be bright green."; |
| + } |
| +} |
| + |
| } // namespace blink |