Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(82)

Side by Side Diff: third_party/WebKit/Source/core/dom/custom/CustomElementTestHelpers.h

Issue 2443543002: createElement should not transmit exceptions but report them. (Closed)
Patch Set: Rebaseline tests. Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « third_party/WebKit/Source/core/dom/custom/CustomElementDefinition.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #ifndef CustomElementTestHelpers_h 5 #ifndef CustomElementTestHelpers_h
6 #define CustomElementTestHelpers_h 6 #define CustomElementTestHelpers_h
7 7
8 #include "bindings/core/v8/ExceptionState.h" 8 #include "bindings/core/v8/ExceptionState.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 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 return false; 58 return false;
59 constructionStack().last().clear(); 59 constructionStack().last().clear();
60 return true; 60 return true;
61 } 61 }
62 62
63 HTMLElement* createElementSync(Document& document, 63 HTMLElement* createElementSync(Document& document,
64 const QualifiedName&) override { 64 const QualifiedName&) override {
65 return createElementForConstructor(document); 65 return createElementForConstructor(document);
66 } 66 }
67 67
68 HTMLElement* createElementSync(Document& document,
69 const QualifiedName&,
70 ExceptionState&) override {
71 return createElementForConstructor(document);
72 }
73
74 bool hasConnectedCallback() const override { return false; } 68 bool hasConnectedCallback() const override { return false; }
75 bool hasDisconnectedCallback() const override { return false; } 69 bool hasDisconnectedCallback() const override { return false; }
76 bool hasAdoptedCallback() const override { return false; } 70 bool hasAdoptedCallback() const override { return false; }
77 71
78 void runConnectedCallback(Element*) override { 72 void runConnectedCallback(Element*) override {
79 NOTREACHED() << "definition does not have connected callback"; 73 NOTREACHED() << "definition does not have connected callback";
80 } 74 }
81 75
82 void runDisconnectedCallback(Element*) override { 76 void runDisconnectedCallback(Element*) override {
83 NOTREACHED() << "definition does not have disconnected callback"; 77 NOTREACHED() << "definition does not have disconnected callback";
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
138 private: 132 private:
139 Member<Document> m_document; 133 Member<Document> m_document;
140 AtomicString m_namespaceURI; 134 AtomicString m_namespaceURI;
141 AtomicString m_localName; 135 AtomicString m_localName;
142 std::vector<std::pair<QualifiedName, AtomicString>> m_attributes; 136 std::vector<std::pair<QualifiedName, AtomicString>> m_attributes;
143 }; 137 };
144 138
145 } // namespace blink 139 } // namespace blink
146 140
147 #endif // CustomElementTestHelpers_h 141 #endif // CustomElementTestHelpers_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/dom/custom/CustomElementDefinition.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698