| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 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 | 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/custom/CustomElementsRegistry.h" | 5 #include "core/dom/custom/CustomElementsRegistry.h" |
| 6 | 6 |
| 7 #include "bindings/core/v8/ExceptionState.h" | 7 #include "bindings/core/v8/ExceptionState.h" |
| 8 #include "bindings/core/v8/ScriptValue.h" | 8 #include "bindings/core/v8/ScriptValue.h" |
| 9 #include "core/dom/Document.h" | 9 #include "core/dom/Document.h" |
| 10 #include "core/dom/Element.h" | 10 #include "core/dom/Element.h" |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 64 private: | 64 private: |
| 65 Persistent<Document> m_document; | 65 Persistent<Document> m_document; |
| 66 Persistent<CustomElementsRegistry> m_registry; | 66 Persistent<CustomElementsRegistry> m_registry; |
| 67 }; | 67 }; |
| 68 | 68 |
| 69 class CustomElementsRegistryFrameTest : public CustomElementsRegistryTestBase { | 69 class CustomElementsRegistryFrameTest : public CustomElementsRegistryTestBase { |
| 70 protected: | 70 protected: |
| 71 void SetUp() override | 71 void SetUp() override |
| 72 { | 72 { |
| 73 CustomElementsRegistryTestBase::SetUp(); | 73 CustomElementsRegistryTestBase::SetUp(); |
| 74 m_page.reset(DummyPageHolder::create(IntSize(1, 1)).leakPtr()); | 74 m_page.reset(DummyPageHolder::create(IntSize(1, 1)).release()); |
| 75 } | 75 } |
| 76 | 76 |
| 77 void TearDown() override | 77 void TearDown() override |
| 78 { | 78 { |
| 79 m_page = nullptr; | 79 m_page = nullptr; |
| 80 CustomElementsRegistryTestBase::TearDown(); | 80 CustomElementsRegistryTestBase::TearDown(); |
| 81 } | 81 } |
| 82 | 82 |
| 83 Document& document() override { return m_page->document(); } | 83 Document& document() override { return m_page->document(); } |
| 84 | 84 |
| (...skipping 364 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 449 << "remove() should invoke disconnectedCallback"; | 449 << "remove() should invoke disconnectedCallback"; |
| 450 | 450 |
| 451 EXPECT_EQ(1u, definition->m_logs.size()) | 451 EXPECT_EQ(1u, definition->m_logs.size()) |
| 452 << "remove() should not invoke other callbacks"; | 452 << "remove() should not invoke other callbacks"; |
| 453 } | 453 } |
| 454 | 454 |
| 455 // TODO(dominicc): Add tests which adjust the "is" attribute when type | 455 // TODO(dominicc): Add tests which adjust the "is" attribute when type |
| 456 // extensions are implemented. | 456 // extensions are implemented. |
| 457 | 457 |
| 458 } // namespace blink | 458 } // namespace blink |
| OLD | NEW |