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

Unified Diff: third_party/WebKit/LayoutTests/fast/dom/Attr/change-id-via-attr-node-value.html

Issue 2781993003: Move tests for Attr interface to LayoutTests/dom/attr/. (Closed)
Patch Set: Created 3 years, 9 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: third_party/WebKit/LayoutTests/fast/dom/Attr/change-id-via-attr-node-value.html
diff --git a/third_party/WebKit/LayoutTests/fast/dom/Attr/change-id-via-attr-node-value.html b/third_party/WebKit/LayoutTests/fast/dom/Attr/change-id-via-attr-node-value.html
deleted file mode 100644
index 1669653be9009f82f8744bcdae5f2f833143a1e8..0000000000000000000000000000000000000000
--- a/third_party/WebKit/LayoutTests/fast/dom/Attr/change-id-via-attr-node-value.html
+++ /dev/null
@@ -1,83 +0,0 @@
-<!DOCTYPE HTML>
-<html>
-<head>
-<script src="../../../resources/js-test.js"></script>
-</head>
-<body id="a">
-<script>
-
-description("Test that different ways of changing an element's id all work properly.");
-
-debug("\n1. Check id after parsing.");
-shouldBe('document.getElementById("a")', 'document.body');
-shouldBe('document.body.id', '"a"');
-shouldBe('document.body.getAttributeNode("id").value', '"a"');
-
-debug("\n2. Change Attr.value.");
-document.body.getAttributeNode("id").value = "b";
-shouldBe('document.getElementById("a")', 'null');
-shouldBe('document.getElementById("b")', 'document.body');
-shouldBe('document.body.getAttributeNode("id").value', '"b"');
-
-debug("\n3. Change HTMLElement.id.");
-document.body.id = "c";
-shouldBe('document.getElementById("b")', 'null');
-shouldBe('document.getElementById("c")', 'document.body');
-shouldBe('document.body.getAttributeNode("id").value', '"c"');
-
-debug("\n4. Change id attribute via setAttribute().");
-document.body.setAttribute("id", "d");
-shouldBe('document.getElementById("c")', 'null');
-shouldBe('document.getElementById("d")', 'document.body');
-shouldBe('document.body.getAttributeNode("id").value', '"d"');
-
-debug("\n5. Change id attribute via setAttributeNS().");
-document.body.setAttributeNS(null, "id", "e");
-shouldBe('document.getElementById("d")', 'null');
-shouldBe('document.getElementById("e")', 'document.body');
-shouldBe('document.body.getAttributeNode("id").value', '"e"');
-
-var attrNode = document.body.getAttributeNode("id");
-
-debug("\n6. Change Attr.nodeValue.");
-document.body.getAttributeNode("id").nodeValue = "f";
-shouldBe('document.getElementById("e")', 'null');
-shouldBe('document.getElementById("f")', 'document.body');
-shouldBe('document.body.id', '"f"');
-shouldBe('document.body.getAttribute("id")', '"f"');
-shouldBe('attrNode.value', '"f"');
-
-debug("\n12. Chnaging Attr.value.");
-attrNode.value = "hi";
-shouldBe('document.getElementById("i")', 'null');
-shouldBe('document.getElementById("hi")', 'document.body');
-shouldBe('document.body.id', '"hi"');
-shouldBe('document.body.getAttribute("id")', '"hi"');
-shouldBe('attrNode.value', '"hi"');
-
-debug("\n21. Remove an Attr node.");
-document.body.removeAttributeNode(attrNode);
-shouldBe('document.body.id', '""');
-shouldBe('document.getElementById("mn")', 'null');
-shouldBe('document.body.getAttribute("id")', 'null');
-shouldBe('document.body.getAttributeNode("id")', 'null');
-
-debug("\n22. Add an Attr node.");
-var attrNode = document.createAttribute("id");
-attrNode.value = "o";
-document.body.setAttributeNode(attrNode);
-shouldBe('document.getElementById("o")', 'document.body');
-shouldBe('document.body.id', '"o"');
-shouldBe('document.body.getAttribute("id")', '"o"');
-
-debug("\n23. Add an Attr node over an existing one.");
-var attrNode = document.createAttribute("id");
-attrNode.value = "p";
-document.body.setAttributeNode(attrNode);
-shouldBe('document.getElementById("o")', 'null');
-shouldBe('document.getElementById("p")', 'document.body');
-shouldBe('document.body.id', '"p"');
-shouldBe('document.body.getAttribute("id")', '"p"');
-</script>
-</body>
-</html>

Powered by Google App Engine
This is Rietveld 408576698