Bug 1497331 [wpt PR 13370] - Add elementsFromPoint() tests for non-atomic inlines., a=testonly
authorMorten Stenshorne <mstensho@chromium.org>
Thu, 11 Oct 2018 09:30:49 +0000
changeset 496753 73f3a0ec3ee83eeb084e9138badb4c45298f1c90
parent 496752 a798aebf9902cbc103a71142c8d9119b3b8b6a41
child 496754 778947aa35feb8fd5ae1e8d192d98e1bec585bd3
push id9984
push userffxbld-merge
push dateMon, 15 Oct 2018 21:07:35 +0000
treeherdermozilla-beta@183d27ea8570 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerstestonly
bugs1497331, 13370, 1261436, 597027
milestone64.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1497331 [wpt PR 13370] - Add elementsFromPoint() tests for non-atomic inlines., a=testonly Automatic update from web-platform-testsAdd elementsFromPoint() tests for non-atomic inlines. Added a comment to LayoutInline, pointing out that LayoutNG is doing the right thing already, while legacy is wrong. Cq-Include-Trybots: luci.chromium.try‚Äč:linux_layout_tests_layout_ng Change-Id: I026404af70c33b0a94900773636d5e138a725976 Reviewed-on: https://chromium-review.googlesource.com/c/1261436 Reviewed-by: Aleks Totic <atotic@chromium.org> Reviewed-by: Koji Ishii <kojii@chromium.org> Commit-Queue: Morten Stenshorne <mstensho@chromium.org> Cr-Commit-Position: refs/heads/master@{#597027} -- wpt-commits: 0d90b8b3faaf4c786f359beb5d77bcd894cb9a47 wpt-pr: 13370
testing/web-platform/tests/css/cssom-view/elementsFromPoint-inline-htb-ltr.html
testing/web-platform/tests/css/cssom-view/elementsFromPoint-inline-htb-rtl.html
testing/web-platform/tests/css/cssom-view/elementsFromPoint-inline-vlr-ltr.html
testing/web-platform/tests/css/cssom-view/elementsFromPoint-inline-vlr-rtl.html
testing/web-platform/tests/css/cssom-view/elementsFromPoint-inline-vrl-ltr.html
testing/web-platform/tests/css/cssom-view/elementsFromPoint-inline-vrl-rtl.html
new file mode 100644
--- /dev/null
+++ b/testing/web-platform/tests/css/cssom-view/elementsFromPoint-inline-htb-ltr.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<link rel="author" title="Morten Stenshorne" href="mstensho@chromium.org">
+<link rel="help" href="https://www.w3.org/TR/cssom-view-1/#extensions-to-the-document-interface">
+<div id="container" style="width:200px; height:200px; writing-mode:horizontal-tb; direction:ltr;">
+  <span id="target">target</span>
+</div>
+<script src="/resources/testharness.js"></script>
+<script src="/resources/testharnessreport.js"></script>
+<script>
+  test(()=> {
+      var elements = document.elementsFromPoint(15, 15);
+      assert_equals(elements.length, 4);
+      assert_equals(elements[0].id, "target");
+      assert_equals(elements[1].id, "container");
+      assert_equals(elements[2].nodeName, "BODY");
+      assert_equals(elements[3].nodeName, "HTML");
+  }, "elementsFromPoint should return all elements under a point");
+</script>
new file mode 100644
--- /dev/null
+++ b/testing/web-platform/tests/css/cssom-view/elementsFromPoint-inline-htb-rtl.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<link rel="author" title="Morten Stenshorne" href="mstensho@chromium.org">
+<link rel="help" href="https://www.w3.org/TR/cssom-view-1/#extensions-to-the-document-interface">
+<div id="container" style="width:200px; height:200px; writing-mode:horizontal-tb; direction:rtl;">
+  <span id="target">target</span>
+</div>
+<script src="/resources/testharness.js"></script>
+<script src="/resources/testharnessreport.js"></script>
+<script>
+  test(()=> {
+      var elements = document.elementsFromPoint(200, 15);
+      assert_equals(elements.length, 4);
+      assert_equals(elements[0].id, "target");
+      assert_equals(elements[1].id, "container");
+      assert_equals(elements[2].nodeName, "BODY");
+      assert_equals(elements[3].nodeName, "HTML");
+  }, "elementsFromPoint should return all elements under a point");
+</script>
new file mode 100644
--- /dev/null
+++ b/testing/web-platform/tests/css/cssom-view/elementsFromPoint-inline-vlr-ltr.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<link rel="author" title="Morten Stenshorne" href="mstensho@chromium.org">
+<link rel="help" href="https://www.w3.org/TR/cssom-view-1/#extensions-to-the-document-interface">
+<div id="container" style="width:200px; height:200px; writing-mode:vertical-lr; direction:ltr;">
+  <span id="target">target</span>
+</div>
+<script src="/resources/testharness.js"></script>
+<script src="/resources/testharnessreport.js"></script>
+<script>
+  test(()=> {
+      var elements = document.elementsFromPoint(15, 15);
+      assert_equals(elements.length, 4);
+      assert_equals(elements[0].id, "target");
+      assert_equals(elements[1].id, "container");
+      assert_equals(elements[2].nodeName, "BODY");
+      assert_equals(elements[3].nodeName, "HTML");
+  }, "elementsFromPoint should return all elements under a point");
+</script>
new file mode 100644
--- /dev/null
+++ b/testing/web-platform/tests/css/cssom-view/elementsFromPoint-inline-vlr-rtl.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<link rel="author" title="Morten Stenshorne" href="mstensho@chromium.org">
+<link rel="help" href="https://www.w3.org/TR/cssom-view-1/#extensions-to-the-document-interface">
+<div id="container" style="width:200px; height:200px; writing-mode:vertical-lr; direction:rtl;">
+  <span id="target">target</span>
+</div>
+<script src="/resources/testharness.js"></script>
+<script src="/resources/testharnessreport.js"></script>
+<script>
+  test(()=> {
+      var elements = document.elementsFromPoint(15, 200);
+      assert_equals(elements.length, 4);
+      assert_equals(elements[0].id, "target");
+      assert_equals(elements[1].id, "container");
+      assert_equals(elements[2].nodeName, "BODY");
+      assert_equals(elements[3].nodeName, "HTML");
+  }, "elementsFromPoint should return all elements under a point");
+</script>
new file mode 100644
--- /dev/null
+++ b/testing/web-platform/tests/css/cssom-view/elementsFromPoint-inline-vrl-ltr.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<link rel="author" title="Morten Stenshorne" href="mstensho@chromium.org">
+<link rel="help" href="https://www.w3.org/TR/cssom-view-1/#extensions-to-the-document-interface">
+<div id="container" style="width:200px; height:200px; writing-mode:vertical-rl; direction:ltr;">
+  <span id="target">target</span>
+</div>
+<script src="/resources/testharness.js"></script>
+<script src="/resources/testharnessreport.js"></script>
+<script>
+  test(()=> {
+      var elements = document.elementsFromPoint(200, 15);
+      assert_equals(elements.length, 4);
+      assert_equals(elements[0].id, "target");
+      assert_equals(elements[1].id, "container");
+      assert_equals(elements[2].nodeName, "BODY");
+      assert_equals(elements[3].nodeName, "HTML");
+  }, "elementsFromPoint should return all elements under a point");
+</script>
new file mode 100644
--- /dev/null
+++ b/testing/web-platform/tests/css/cssom-view/elementsFromPoint-inline-vrl-rtl.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<link rel="author" title="Morten Stenshorne" href="mstensho@chromium.org">
+<link rel="help" href="https://www.w3.org/TR/cssom-view-1/#extensions-to-the-document-interface">
+<div id="container" style="width:200px; height:200px; writing-mode:vertical-rl; direction:rtl;">
+  <span id="target">target</span>
+</div>
+<script src="/resources/testharness.js"></script>
+<script src="/resources/testharnessreport.js"></script>
+<script>
+  test(()=> {
+      var elements = document.elementsFromPoint(200, 200);
+      assert_equals(elements.length, 4);
+      assert_equals(elements[0].id, "target");
+      assert_equals(elements[1].id, "container");
+      assert_equals(elements[2].nodeName, "BODY");
+      assert_equals(elements[3].nodeName, "HTML");
+  }, "elementsFromPoint should return all elements under a point");
+</script>