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

Unified Diff: LayoutTests/fast/dom/Document/clone-node.html

Issue 23437003: Implement cloneNode for Document (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 4 months 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 side-by-side diff with in-line comments
Download patch
Index: LayoutTests/fast/dom/Document/clone-node.html
diff --git a/LayoutTests/fast/dom/Document/clone-node.html b/LayoutTests/fast/dom/Document/clone-node.html
new file mode 100644
index 0000000000000000000000000000000000000000..2a6c9c62c1e32a3b2f56c9bfb051dbfbfe0a9bda
--- /dev/null
+++ b/LayoutTests/fast/dom/Document/clone-node.html
@@ -0,0 +1,23 @@
+<!DOCTYPE html>
+<link rel="help" href="http://dom.spec.whatwg.org/#dom-node-clonenode">
+<script src="../../js/resources/js-test-pre.js"></script>
+<script>
+description('Tests cloneNode for Document.');
+
+function className(object) {
+ return Object.prototype.toString.call(object).slice(8, -1);
+}
+
+var doc = document.implementation.createDocument('', 'root', null);
+
+shouldBe('doc.cloneNode(false).__proto__', 'Document.prototype');
+shouldBeEqualToString('className(doc.cloneNode(false))', 'Document');
+shouldBeEqualToString('doc.cloneNode(true).documentElement.localName', 'root');
+shouldBeEqualToString('document.cloneNode(true).compatMode', 'CSS1Compat');
+shouldBe('document.cloneNode(false).URL', 'document.URL');
+shouldBe('document.cloneNode(false).baseURI', 'document.baseURI');
+shouldBe('document.cloneNode(false).characterSet', 'document.characterSet');
+
+</script>
+<script src="../../js/resources/js-test-post.js"></script>
+</body>

Powered by Google App Engine
This is Rietveld 408576698