WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
[patch]
Patch
bug-91704-20120820104704.patch (text/plain), 18.91 KB, created by
Shinya Kawanaka
on 2012-08-19 18:47:43 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Shinya Kawanaka
Created:
2012-08-19 18:47:43 PDT
Size:
18.91 KB
patch
obsolete
>Subversion Revision: 125983 >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index 52812cc57d489a5025bb04569e1632759b25e958..b17af0e38afef85239e60de9fcea537a39e93b10 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,65 @@ >+2012-08-16 Shinya Kawanaka <shinyak@chromium.org> >+ >+ ShadowRoot.cloneNode() must always throw a DATA_CLONE_ERR exception. >+ https://bugs.webkit.org/show_bug.cgi?id=91704 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ According to the spec, ShadowRoot.cloneNode() should throw a DATA_CLONE_ERR exception. The existing implementation >+ returned null object instead. >+ >+ We change the cloneNode() interface so that we can throw an exception from cloneNode(). >+ >+ Test: fast/dom/shadow/shadowroot-clonenode.html >+ >+ * dom/Attr.cpp: >+ (WebCore::Attr::cloneNode): >+ * dom/Attr.h: >+ * dom/CDATASection.cpp: >+ (WebCore::CDATASection::cloneNode): >+ * dom/CDATASection.h: >+ (CDATASection): >+ * dom/Comment.cpp: >+ (WebCore::Comment::cloneNode): >+ * dom/Comment.h: >+ (Comment): >+ * dom/Document.cpp: >+ (WebCore::Document::cloneNode): >+ * dom/Document.h: >+ (Document): >+ * dom/DocumentFragment.cpp: >+ (WebCore::DocumentFragment::cloneNode): >+ * dom/DocumentFragment.h: >+ (DocumentFragment): >+ * dom/DocumentType.cpp: >+ (WebCore::DocumentType::cloneNode): >+ * dom/DocumentType.h: >+ (DocumentType): >+ * dom/Element.cpp: >+ (WebCore::Element::cloneNode): >+ * dom/Element.h: >+ (Element): >+ * dom/EntityReference.cpp: >+ (WebCore::EntityReference::cloneNode): >+ * dom/EntityReference.h: >+ (EntityReference): >+ * dom/Node.h: >+ (Node): >+ (WebCore::Node::cloneNode): >+ * dom/Node.idl: >+ * dom/ProcessingInstruction.cpp: >+ (WebCore::ProcessingInstruction::cloneNode): >+ * dom/ProcessingInstruction.h: >+ (ProcessingInstruction): >+ * dom/ShadowRoot.cpp: >+ (WebCore::ShadowRoot::cloneNode): >+ * dom/ShadowRoot.h: >+ (ShadowRoot): >+ * dom/Text.cpp: >+ (WebCore::Text::cloneNode): >+ * dom/Text.h: >+ (Text): >+ > 2012-08-19 Mike West <mkwst@chromium.org> > > CSP 1.1: Add 'plugin-types' and 'form-action' DOM API. >diff --git a/Source/WebCore/dom/Attr.cpp b/Source/WebCore/dom/Attr.cpp >index 95c3fe0526a74b365a4e6ed9f8c1a5d7c1df66ae..d6e29bd18c6e9fc1d10bf518699e5ecd9de423e8 100644 >--- a/Source/WebCore/dom/Attr.cpp >+++ b/Source/WebCore/dom/Attr.cpp >@@ -138,7 +138,7 @@ void Attr::setNodeValue(const String& v, ExceptionCode& ec) > setValue(v, ec); > } > >-PassRefPtr<Node> Attr::cloneNode(bool /*deep*/) >+PassRefPtr<Node> Attr::cloneNode(bool /*deep*/, ExceptionCode&) > { > RefPtr<Attr> clone = adoptRef(new Attr(document(), qualifiedName(), value())); > cloneChildNodes(clone.get()); >diff --git a/Source/WebCore/dom/Attr.h b/Source/WebCore/dom/Attr.h >index 8e760aa258783f2c0bd88eddcea7494ed6fc6208..86b3c4a60f24369ce68c1bfe16691fd97453deb7 100644 >--- a/Source/WebCore/dom/Attr.h >+++ b/Source/WebCore/dom/Attr.h >@@ -81,7 +81,7 @@ private: > > virtual String nodeValue() const OVERRIDE { return value(); } > virtual void setNodeValue(const String&, ExceptionCode&); >- virtual PassRefPtr<Node> cloneNode(bool deep); >+ virtual PassRefPtr<Node> cloneNode(bool deep, ExceptionCode&); > > virtual bool isAttributeNode() const { return true; } > virtual bool childTypeAllowed(NodeType) const; >diff --git a/Source/WebCore/dom/CDATASection.cpp b/Source/WebCore/dom/CDATASection.cpp >index 33a3acc5860cfe7602acf7cbb609fe3de1c825e2..2b39e8083375312c4f134d8ededb7d43081f23ac 100644 >--- a/Source/WebCore/dom/CDATASection.cpp >+++ b/Source/WebCore/dom/CDATASection.cpp >@@ -46,7 +46,7 @@ Node::NodeType CDATASection::nodeType() const > return CDATA_SECTION_NODE; > } > >-PassRefPtr<Node> CDATASection::cloneNode(bool /*deep*/) >+PassRefPtr<Node> CDATASection::cloneNode(bool /*deep*/, ExceptionCode&) > { > return create(document(), data()); > } >diff --git a/Source/WebCore/dom/CDATASection.h b/Source/WebCore/dom/CDATASection.h >index d7aca9d69a4e1321950acd7675ba58a8f9594bc0..4c26573f7d34be940ba31fe044e7e7d2ad5b5347 100644 >--- a/Source/WebCore/dom/CDATASection.h >+++ b/Source/WebCore/dom/CDATASection.h >@@ -36,7 +36,7 @@ private: > > virtual String nodeName() const; > virtual NodeType nodeType() const; >- virtual PassRefPtr<Node> cloneNode(bool deep); >+ virtual PassRefPtr<Node> cloneNode(bool deep, ExceptionCode&); > virtual bool childTypeAllowed(NodeType) const; > virtual PassRefPtr<Text> virtualCreate(const String&); > }; >diff --git a/Source/WebCore/dom/Comment.cpp b/Source/WebCore/dom/Comment.cpp >index c2f0582ecef06dc453f459a95d5693c4e9c0a10a..900bcd1738c8c95262e0f1d16589af47d2dd462d 100644 >--- a/Source/WebCore/dom/Comment.cpp >+++ b/Source/WebCore/dom/Comment.cpp >@@ -46,7 +46,7 @@ Node::NodeType Comment::nodeType() const > return COMMENT_NODE; > } > >-PassRefPtr<Node> Comment::cloneNode(bool /*deep*/) >+PassRefPtr<Node> Comment::cloneNode(bool /*deep*/, ExceptionCode&) > { > return create(document(), data()); > } >diff --git a/Source/WebCore/dom/Comment.h b/Source/WebCore/dom/Comment.h >index 9db1f31fd109a06ed993625aa9353581bf7782e4..e83445120d1eb2737bda0eca0eb70d1587e1ebe2 100644 >--- a/Source/WebCore/dom/Comment.h >+++ b/Source/WebCore/dom/Comment.h >@@ -36,7 +36,7 @@ private: > > virtual String nodeName() const; > virtual NodeType nodeType() const; >- virtual PassRefPtr<Node> cloneNode(bool deep); >+ virtual PassRefPtr<Node> cloneNode(bool deep, ExceptionCode&); > virtual bool childTypeAllowed(NodeType) const; > }; > >diff --git a/Source/WebCore/dom/Document.cpp b/Source/WebCore/dom/Document.cpp >index 0747da225460faf7b8c327de2405980a991bf8d0..995445046f386469965c8a5af9db6820e14f8228 100644 >--- a/Source/WebCore/dom/Document.cpp >+++ b/Source/WebCore/dom/Document.cpp >@@ -3284,7 +3284,7 @@ bool Document::canReplaceChild(Node* newChild, Node* oldChild) > return true; > } > >-PassRefPtr<Node> Document::cloneNode(bool /*deep*/) >+PassRefPtr<Node> Document::cloneNode(bool /*deep*/, ExceptionCode&) > { > // Spec says cloning Document nodes is "implementation dependent" > // so we do not support it... >diff --git a/Source/WebCore/dom/Document.h b/Source/WebCore/dom/Document.h >index cb470cff41cf147ea13e94981758c61ac032286c..2704c55800250903f50776d74649c442a6a79a4f 100644 >--- a/Source/WebCore/dom/Document.h >+++ b/Source/WebCore/dom/Document.h >@@ -1202,7 +1202,7 @@ private: > virtual String nodeName() const; > virtual NodeType nodeType() const; > virtual bool childTypeAllowed(NodeType) const; >- virtual PassRefPtr<Node> cloneNode(bool deep); >+ virtual PassRefPtr<Node> cloneNode(bool deep, ExceptionCode&); > virtual bool canReplaceChild(Node* newChild, Node* oldChild); > > virtual void refScriptExecutionContext() { ref(); } >diff --git a/Source/WebCore/dom/DocumentFragment.cpp b/Source/WebCore/dom/DocumentFragment.cpp >index f7cfadfcc79f31d51663eaac042b345da734c19a..77ebc2bdf3d7aae613068b17b4d08dafcefa37f4 100644 >--- a/Source/WebCore/dom/DocumentFragment.cpp >+++ b/Source/WebCore/dom/DocumentFragment.cpp >@@ -68,7 +68,7 @@ bool DocumentFragment::childTypeAllowed(NodeType type) const > } > } > >-PassRefPtr<Node> DocumentFragment::cloneNode(bool deep) >+PassRefPtr<Node> DocumentFragment::cloneNode(bool deep, ExceptionCode&) > { > RefPtr<DocumentFragment> clone = create(document()); > if (deep) >diff --git a/Source/WebCore/dom/DocumentFragment.h b/Source/WebCore/dom/DocumentFragment.h >index 3af5f1b28faa1bea83f7750fdd1e7fff37ea34d3..cefe1388b529ed7f251a4360e2bff0eb49d05d5f 100644 >--- a/Source/WebCore/dom/DocumentFragment.h >+++ b/Source/WebCore/dom/DocumentFragment.h >@@ -44,7 +44,7 @@ protected: > > private: > virtual NodeType nodeType() const; >- virtual PassRefPtr<Node> cloneNode(bool deep); >+ virtual PassRefPtr<Node> cloneNode(bool deep, ExceptionCode&); > virtual bool childTypeAllowed(NodeType) const; > }; > >diff --git a/Source/WebCore/dom/DocumentType.cpp b/Source/WebCore/dom/DocumentType.cpp >index cd1d48534699ba859a1f33a1bd2c6f91cb84e384..29b5c7d4463f8c4166c3889336601bce452a0e02 100644 >--- a/Source/WebCore/dom/DocumentType.cpp >+++ b/Source/WebCore/dom/DocumentType.cpp >@@ -51,7 +51,7 @@ Node::NodeType DocumentType::nodeType() const > return DOCUMENT_TYPE_NODE; > } > >-PassRefPtr<Node> DocumentType::cloneNode(bool /*deep*/) >+PassRefPtr<Node> DocumentType::cloneNode(bool /*deep*/, ExceptionCode&) > { > return create(document(), m_name, m_publicId, m_systemId); > } >diff --git a/Source/WebCore/dom/DocumentType.h b/Source/WebCore/dom/DocumentType.h >index 6c641245917d5c32db0abbfc7b2b73e772c44c43..65416164c0066a58defeb5ecdac795a4759d89ce 100644 >--- a/Source/WebCore/dom/DocumentType.h >+++ b/Source/WebCore/dom/DocumentType.h >@@ -52,7 +52,7 @@ private: > virtual KURL baseURI() const; > virtual String nodeName() const; > virtual NodeType nodeType() const; >- virtual PassRefPtr<Node> cloneNode(bool deep); >+ virtual PassRefPtr<Node> cloneNode(bool deep, ExceptionCode&); > > virtual InsertionNotificationRequest insertedInto(ContainerNode*) OVERRIDE; > virtual void removedFrom(ContainerNode*) OVERRIDE; >diff --git a/Source/WebCore/dom/Element.cpp b/Source/WebCore/dom/Element.cpp >index 3a8d029b7cb1d8330bc5c756b755af607e64ac68..53d6a29829b8902f7d2219128bf56ffd7e2f5514 100644 >--- a/Source/WebCore/dom/Element.cpp >+++ b/Source/WebCore/dom/Element.cpp >@@ -176,7 +176,7 @@ DEFINE_VIRTUAL_ATTRIBUTE_EVENT_LISTENER(Element, error); > DEFINE_VIRTUAL_ATTRIBUTE_EVENT_LISTENER(Element, focus); > DEFINE_VIRTUAL_ATTRIBUTE_EVENT_LISTENER(Element, load); > >-PassRefPtr<Node> Element::cloneNode(bool deep) >+PassRefPtr<Node> Element::cloneNode(bool deep, ExceptionCode&) > { > return deep ? cloneElementWithChildren() : cloneElementWithoutChildren(); > } >diff --git a/Source/WebCore/dom/Element.h b/Source/WebCore/dom/Element.h >index d056a9d435deb40e82425466991c8b0f7c00a3e7..d9385486f70b64fad90b984b18da7138daf663a4 100644 >--- a/Source/WebCore/dom/Element.h >+++ b/Source/WebCore/dom/Element.h >@@ -501,7 +501,7 @@ private: > > // cloneNode is private so that non-virtual cloneElementWithChildren and cloneElementWithoutChildren > // are used instead. >- virtual PassRefPtr<Node> cloneNode(bool deep); >+ virtual PassRefPtr<Node> cloneNode(bool deep, ExceptionCode&); > virtual PassRefPtr<Element> cloneElementWithoutAttributesAndChildren(); > > QualifiedName m_tagName; >diff --git a/Source/WebCore/dom/EntityReference.cpp b/Source/WebCore/dom/EntityReference.cpp >index 72944ec5210720fcd7c64f771bccf67710003cd3..fb9e2478cff190ca40f6888f4a6a986a5abc2b43 100644 >--- a/Source/WebCore/dom/EntityReference.cpp >+++ b/Source/WebCore/dom/EntityReference.cpp >@@ -46,7 +46,7 @@ Node::NodeType EntityReference::nodeType() const > return ENTITY_REFERENCE_NODE; > } > >-PassRefPtr<Node> EntityReference::cloneNode(bool) >+PassRefPtr<Node> EntityReference::cloneNode(bool, ExceptionCode&) > { > return create(document(), m_entityName); > } >diff --git a/Source/WebCore/dom/EntityReference.h b/Source/WebCore/dom/EntityReference.h >index 7a6f6c36bafa8f923bd18aff34b68b376c3f5927..49f80161a753ede058cb6a2a78c3499bca98311a 100644 >--- a/Source/WebCore/dom/EntityReference.h >+++ b/Source/WebCore/dom/EntityReference.h >@@ -35,7 +35,7 @@ private: > > virtual String nodeName() const; > virtual NodeType nodeType() const; >- virtual PassRefPtr<Node> cloneNode(bool deep); >+ virtual PassRefPtr<Node> cloneNode(bool deep, ExceptionCode&); > > String m_entityName; > }; >diff --git a/Source/WebCore/dom/Node.h b/Source/WebCore/dom/Node.h >index 141ce96bb5eb29ee2ca847b1c51db5b1c8d5bbcf..46ec0977a38f14cf8cd4423577e809ef12c7fcf2 100644 >--- a/Source/WebCore/dom/Node.h >+++ b/Source/WebCore/dom/Node.h >@@ -27,6 +27,7 @@ > > #include "EditingBoundary.h" > #include "EventTarget.h" >+#include "ExceptionCodePlaceholder.h" > #include "KURLHash.h" > #include "LayoutTypes.h" > #include "MutationObserver.h" >@@ -186,7 +187,8 @@ public: > > void remove(ExceptionCode&); > bool hasChildNodes() const { return firstChild(); } >- virtual PassRefPtr<Node> cloneNode(bool deep) = 0; >+ virtual PassRefPtr<Node> cloneNode(bool deep, ExceptionCode&) = 0; >+ PassRefPtr<Node> cloneNode(bool deep) { return cloneNode(deep, ASSERT_NO_EXCEPTION); } > const AtomicString& localName() const { return virtualLocalName(); } > const AtomicString& namespaceURI() const { return virtualNamespaceURI(); } > const AtomicString& prefix() const { return virtualPrefix(); } >diff --git a/Source/WebCore/dom/Node.idl b/Source/WebCore/dom/Node.idl >index fc4a882abcc4658fe9bae2f5155b3be9692e17a7..85feaee127068539af16c6338598cdc32f00e819 100644 >--- a/Source/WebCore/dom/Node.idl >+++ b/Source/WebCore/dom/Node.idl >@@ -79,7 +79,9 @@ module core { > raises(DOMException); > > boolean hasChildNodes(); >- Node cloneNode(in [Optional=DefaultIsUndefined] boolean deep); >+ Node cloneNode(in [Optional=DefaultIsUndefined] boolean deep) >+ raises(DOMException); >+ > void normalize(); > > // Introduced in DOM Level 2: >diff --git a/Source/WebCore/dom/ProcessingInstruction.cpp b/Source/WebCore/dom/ProcessingInstruction.cpp >index ef13b4690af73babe34681b8c46f06db4023a6f3..87a0198f715057da8c770cf0a7af69f5c3925a63 100644 >--- a/Source/WebCore/dom/ProcessingInstruction.cpp >+++ b/Source/WebCore/dom/ProcessingInstruction.cpp >@@ -97,7 +97,7 @@ void ProcessingInstruction::setNodeValue(const String& nodeValue, ExceptionCode& > setData(nodeValue, ec); > } > >-PassRefPtr<Node> ProcessingInstruction::cloneNode(bool /*deep*/) >+PassRefPtr<Node> ProcessingInstruction::cloneNode(bool /*deep*/, ExceptionCode&) > { > // FIXME: Is it a problem that this does not copy m_localHref? > // What about other data members? >diff --git a/Source/WebCore/dom/ProcessingInstruction.h b/Source/WebCore/dom/ProcessingInstruction.h >index e331e21dfe5e3cd96cb2fe627fe03d147b8b4b61..0960d1574e60325f91ebb48e22d4e7537d1b3f2c 100644 >--- a/Source/WebCore/dom/ProcessingInstruction.h >+++ b/Source/WebCore/dom/ProcessingInstruction.h >@@ -60,7 +60,7 @@ private: > virtual NodeType nodeType() const; > virtual String nodeValue() const; > virtual void setNodeValue(const String&, ExceptionCode&); >- virtual PassRefPtr<Node> cloneNode(bool deep); >+ virtual PassRefPtr<Node> cloneNode(bool deep, ExceptionCode&); > virtual bool offsetInCharacters() const; > virtual int maxCharacterOffset() const; > >diff --git a/Source/WebCore/dom/ShadowRoot.cpp b/Source/WebCore/dom/ShadowRoot.cpp >index b9c481c18986481e19b626f694c206df1221474d..1aadc512673599ff809ddf62389ee6f056968fd9 100644 >--- a/Source/WebCore/dom/ShadowRoot.cpp >+++ b/Source/WebCore/dom/ShadowRoot.cpp >@@ -139,9 +139,10 @@ String ShadowRoot::nodeName() const > return "#shadow-root"; > } > >-PassRefPtr<Node> ShadowRoot::cloneNode(bool) >+PassRefPtr<Node> ShadowRoot::cloneNode(bool, ExceptionCode& ec) > { > // ShadowRoot should not be arbitrarily cloned. >+ ec = DATA_CLONE_ERR; > return 0; > } > >diff --git a/Source/WebCore/dom/ShadowRoot.h b/Source/WebCore/dom/ShadowRoot.h >index d9b425c6083b17af8826e61642781f5525075250..1c9f02cc01a9ed2e2712e5022cf19f7ba57eb1ce 100644 >--- a/Source/WebCore/dom/ShadowRoot.h >+++ b/Source/WebCore/dom/ShadowRoot.h >@@ -97,7 +97,7 @@ private: > explicit ShadowRoot(Document*); > virtual ~ShadowRoot(); > virtual String nodeName() const; >- virtual PassRefPtr<Node> cloneNode(bool deep); >+ virtual PassRefPtr<Node> cloneNode(bool deep, ExceptionCode&); > virtual bool childTypeAllowed(NodeType) const; > virtual void childrenChanged(bool changedByParser, Node* beforeChange, Node* afterChange, int childCountDelta) OVERRIDE; > >diff --git a/Source/WebCore/dom/Text.cpp b/Source/WebCore/dom/Text.cpp >index a00aaeb539ea6c5719c12898537eb6e6cda89733..9945f94aac4916a703e29d9eb15f72ba81f297cc 100644 >--- a/Source/WebCore/dom/Text.cpp >+++ b/Source/WebCore/dom/Text.cpp >@@ -184,7 +184,7 @@ Node::NodeType Text::nodeType() const > return TEXT_NODE; > } > >-PassRefPtr<Node> Text::cloneNode(bool /*deep*/) >+PassRefPtr<Node> Text::cloneNode(bool /*deep*/, ExceptionCode&) > { > return create(document(), data()); > } >diff --git a/Source/WebCore/dom/Text.h b/Source/WebCore/dom/Text.h >index daf38224046fe80945df2dec915074cf2797b6de..8e97e290b7c2f5af4ea896a573a0fdc3f605fc39 100644 >--- a/Source/WebCore/dom/Text.h >+++ b/Source/WebCore/dom/Text.h >@@ -58,7 +58,7 @@ protected: > private: > virtual String nodeName() const; > virtual NodeType nodeType() const; >- virtual PassRefPtr<Node> cloneNode(bool deep); >+ virtual PassRefPtr<Node> cloneNode(bool deep, ExceptionCode&); > virtual bool rendererIsNeeded(const NodeRenderingContext&); > virtual RenderObject* createRenderer(RenderArena*, RenderStyle*); > virtual bool childTypeAllowed(NodeType) const; >diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog >index 5b6a28c47dbdb9eac5c17109c9ca6dbef07a190c..6fa123bd5e378e00a81080a8a6d892899d97fe59 100644 >--- a/LayoutTests/ChangeLog >+++ b/LayoutTests/ChangeLog >@@ -1,3 +1,13 @@ >+2012-08-16 Shinya Kawanaka <shinyak@chromium.org> >+ >+ ShadowRoot.cloneNode() must always throw a DATA_CLONE_ERR exception. >+ https://bugs.webkit.org/show_bug.cgi?id=91704 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * fast/dom/shadow/shadowroot-clonenode-expected.txt: Added. >+ * fast/dom/shadow/shadowroot-clonenode.html: Added. >+ > 2012-08-19 Mike West <mkwst@chromium.org> > > CSP 1.1: Add 'plugin-types' and 'form-action' DOM API. >diff --git a/LayoutTests/fast/dom/shadow/shadowroot-clonenode-expected.txt b/LayoutTests/fast/dom/shadow/shadowroot-clonenode-expected.txt >new file mode 100644 >index 0000000000000000000000000000000000000000..7d8d9e881cf1c05f0868fede59adfc28703789ca >--- /dev/null >+++ b/LayoutTests/fast/dom/shadow/shadowroot-clonenode-expected.txt >@@ -0,0 +1,10 @@ >+Calling ShadowRoot.cloneNode() should throw a DATA_CLONE_ERR exception. >+ >+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". >+ >+ >+PASS exceptionCode is DOMException.DATA_CLONE_ERR >+PASS successfullyParsed is true >+ >+TEST COMPLETE >+ >diff --git a/LayoutTests/fast/dom/shadow/shadowroot-clonenode.html b/LayoutTests/fast/dom/shadow/shadowroot-clonenode.html >new file mode 100644 >index 0000000000000000000000000000000000000000..110dcd7dd5c003aaefcf3384eb9372d03617f5d2 >--- /dev/null >+++ b/LayoutTests/fast/dom/shadow/shadowroot-clonenode.html >@@ -0,0 +1,26 @@ >+<!DOCTYPE> >+<html> >+<script src="../../js/resources/js-test-pre.js"></script> >+<script src="resources/polyfill.js"></script> >+ >+<pre id="console"></pre> >+ >+<script> >+description('Calling ShadowRoot.cloneNode() should throw a DATA_CLONE_ERR exception.'); >+ >+var host = document.createElement('div'); >+var shadowRoot = new WebKitShadowRoot(host); >+ >+var exceptionCode = null; >+try { >+ shadowRoot.cloneNode() >+} catch (e) { >+ exceptionCode = e.code; >+} >+ >+shouldBe('exceptionCode', 'DOMException.DATA_CLONE_ERR') >+ >+finishJSTest(); >+</script> >+<script src="../../js/resources/js-test-post.js"></script> >+</html>
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 91704
:
159001
|
159025
|
159317
|
159322
|
162208
|
162211