OLD | NEW |
1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "core/dom/Document.h" | 5 #include "core/dom/Document.h" |
6 #include "core/html/HTMLLinkElement.h" | 6 #include "core/html/HTMLLinkElement.h" |
7 #include "testing/gtest/include/gtest/gtest.h" | 7 #include "testing/gtest/include/gtest/gtest.h" |
8 #include "web/tests/sim/SimRequest.h" | 8 #include "web/tests/sim/SimRequest.h" |
9 #include "web/tests/sim/SimTest.h" | 9 #include "web/tests/sim/SimTest.h" |
10 | 10 |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
45 | 45 |
46 EXPECT_TRUE(GetDocument().GetStyleEngine().NeedsActiveStyleUpdate()); | 46 EXPECT_TRUE(GetDocument().GetStyleEngine().NeedsActiveStyleUpdate()); |
47 Document* import_doc = | 47 Document* import_doc = |
48 toHTMLLinkElement(GetDocument().getElementById("link"))->import(); | 48 toHTMLLinkElement(GetDocument().getElementById("link"))->import(); |
49 ASSERT_TRUE(import_doc); | 49 ASSERT_TRUE(import_doc); |
50 EXPECT_TRUE(import_doc->GetStyleEngine().NeedsActiveStyleUpdate()); | 50 EXPECT_TRUE(import_doc->GetStyleEngine().NeedsActiveStyleUpdate()); |
51 | 51 |
52 import_doc->GetStyleEngine().StyleSheetsForStyleSheetList(*import_doc); | 52 import_doc->GetStyleEngine().StyleSheetsForStyleSheetList(*import_doc); |
53 | 53 |
54 EXPECT_TRUE(GetDocument().GetStyleEngine().NeedsActiveStyleUpdate()); | 54 EXPECT_TRUE(GetDocument().GetStyleEngine().NeedsActiveStyleUpdate()); |
55 EXPECT_FALSE(import_doc->GetStyleEngine().NeedsActiveStyleUpdate()); | 55 EXPECT_TRUE(import_doc->GetStyleEngine().NeedsActiveStyleUpdate()); |
56 } | 56 } |
57 | 57 |
58 } // namespace blink | 58 } // namespace blink |
OLD | NEW |