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

Unified Diff: LayoutTests/fast/dom/DocumentFragment/sibling-rules-under-document-fragment.html

Issue 270503006: Make pseudo-classes selector queries work on DocumentFragment (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Address Esprehn's comments Created 6 years, 7 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
« no previous file with comments | « no previous file | LayoutTests/fast/dom/DocumentFragment/sibling-rules-under-document-fragment-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/fast/dom/DocumentFragment/sibling-rules-under-document-fragment.html
diff --git a/LayoutTests/fast/dom/DocumentFragment/sibling-rules-under-document-fragment.html b/LayoutTests/fast/dom/DocumentFragment/sibling-rules-under-document-fragment.html
new file mode 100644
index 0000000000000000000000000000000000000000..921ed4e8cfe11a71092259a63e2da848238b72d4
--- /dev/null
+++ b/LayoutTests/fast/dom/DocumentFragment/sibling-rules-under-document-fragment.html
@@ -0,0 +1,18 @@
+<script src="../../../resources/js-test.js"></script>
+<script>
+description('Tests :first-child rule under DocumentFragment.');
+
+var fragment = document.createDocumentFragment();
+var div = document.createElement('div');
+var a1 = document.createElement('a');
+var a2 = document.createElement('a');
+
+fragment.appendChild(a1);
+div.appendChild(a2);
+
+var fragmentSelected = fragment.querySelector('a:first-child');
+var elementSelected = div.querySelector('a:first-child');
+
+shouldBe("fragmentSelected", "a1");
+shouldBe("elementSelected", "a2");
+</script>
« no previous file with comments | « no previous file | LayoutTests/fast/dom/DocumentFragment/sibling-rules-under-document-fragment-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698