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

Unified Diff: third_party/WebKit/LayoutTests/accessibility/bounds-calc.html

Issue 2169273004: Switch all LayoutTests to use new accessibility relative bounding box API. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix absolute bounds in AXInlineTextBox::elementRect Created 4 years, 5 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/accessibility/bounds-calc.html
diff --git a/third_party/WebKit/LayoutTests/accessibility/bounds-calc.html b/third_party/WebKit/LayoutTests/accessibility/bounds-calc.html
index b8ef9f9c3adbdd6bb6d80dd2bd8ce850950c5891..2af241fe9a7dce543967eb4fcbc0634278a7b584 100644
--- a/third_party/WebKit/LayoutTests/accessibility/bounds-calc.html
+++ b/third_party/WebKit/LayoutTests/accessibility/bounds-calc.html
@@ -66,9 +66,9 @@ function assertDOMRectSameAsAXRect(id) {
var epsilon = 1;
assert_approx_equals(axObject.boundsX, bounds.left, epsilon, id + " left");
- assert_approx_equals(axObject.boundsY, bounds.top, epsilon, id + " left");
- assert_approx_equals(axObject.boundsWidth, bounds.width, epsilon, id + " left");
- assert_approx_equals(axObject.boundsHeight, bounds.height, epsilon, id + " left");
+ assert_approx_equals(axObject.boundsY, bounds.top, epsilon, id + " top");
+ assert_approx_equals(axObject.boundsWidth, bounds.width, epsilon, id + " width");
+ assert_approx_equals(axObject.boundsHeight, bounds.height, epsilon, id + " height");
}
function assertStaticTextChildDOMRectSameAsAXRect(id) {
@@ -244,6 +244,23 @@ test(function(t) {
}, "Container must be an ancestor in both the AX tree and layout tree.");
</script>
+<div id="container7" class="container" role="group"
+ style="position: absolute; left: 600px; top: 20px; border: 3px solid #eee; margin: 5px; padding: 7px;">
+ <span id="span7" role="group">
+ Before
+ <div style="width: 100px; height: 100px;">Block</div>
+ After
+ </span>
+</div>
+
+<script>
+test(function(t) {
+ assertHasTransform("container7", false);
+ assertHasTransform("span7", false);
+ assertDOMRectSameAsAXRect("span7");
+}, "Test spans inside of absolute-positioned container");
+</script>
+
<script>
if (window.testRunner)
document.body.className = "hideAllContainers";

Powered by Google App Engine
This is Rietveld 408576698