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

Unified Diff: third_party/WebKit/LayoutTests/fast/dom/SelectorAPI/script-tests/viewless-document.js

Issue 2667393002: Stop using script-tests in fast/dom/. (Closed)
Patch Set: . Created 3 years, 11 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/SelectorAPI/script-tests/viewless-document.js
diff --git a/third_party/WebKit/LayoutTests/fast/dom/SelectorAPI/script-tests/viewless-document.js b/third_party/WebKit/LayoutTests/fast/dom/SelectorAPI/script-tests/viewless-document.js
deleted file mode 100644
index 7a9d43e2baca4fec79d15373abd98700078cc57d..0000000000000000000000000000000000000000
--- a/third_party/WebKit/LayoutTests/fast/dom/SelectorAPI/script-tests/viewless-document.js
+++ /dev/null
@@ -1,26 +0,0 @@
-description(
-"This tests that querySelector, querySelectorAll and matchesSelector (webkitMatchesSelector) don't crash when used in a viewless document."
-);
-
-var testDoc = document.implementation.createDocument("http://www.w3.org/1999/xhtml", "html");
-testDoc.documentElement.appendChild(testDoc.createElement("body"));
-testDoc.body.appendChild(testDoc.createElement("p")).id = "p1";
-testDoc.getElementById("p1").appendChild(testDoc.createElement("span")).id = "s1";
-testDoc.body.appendChild(testDoc.createElement("span")).id = "s2";
-testDoc.body.appendChild(testDoc.createElement("div")).className = "d1";
-
-var p1 = testDoc.getElementById("p1");
-var s1 = testDoc.getElementById("s1");
-var s2 = testDoc.getElementById("s2");
-var d1 = testDoc.body.lastChild;
-
-shouldBe("testDoc.querySelector('p')", "p1");
-shouldBe("testDoc.querySelectorAll('span').length", "2");
-shouldBe("testDoc.querySelectorAll('span').item(1)", "s2");
-shouldBe("testDoc.querySelector('.d1')", "d1");
-shouldBe("testDoc.querySelectorAll('p span').length", "1");
-
-shouldBeTrue("p1.webkitMatchesSelector('p')");
-shouldBeTrue("s1.webkitMatchesSelector('p span')");
-shouldBeTrue("s2.webkitMatchesSelector('#s2')");
-shouldBeTrue("d1.webkitMatchesSelector('.d1')");

Powered by Google App Engine
This is Rietveld 408576698