summaryrefslogtreecommitdiffstats
path: root/accessible/tests/browser/scroll
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:13:27 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:13:27 +0000
commit40a355a42d4a9444dc753c04c6608dade2f06a23 (patch)
tree871fc667d2de662f171103ce5ec067014ef85e61 /accessible/tests/browser/scroll
parentAdding upstream version 124.0.1. (diff)
downloadfirefox-40a355a42d4a9444dc753c04c6608dade2f06a23.tar.xz
firefox-40a355a42d4a9444dc753c04c6608dade2f06a23.zip
Adding upstream version 125.0.1.upstream/125.0.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'accessible/tests/browser/scroll')
-rw-r--r--accessible/tests/browser/scroll/browser_test_scroll_bounds.js14
-rw-r--r--accessible/tests/browser/scroll/browser_test_scroll_substring.js5
2 files changed, 14 insertions, 5 deletions
diff --git a/accessible/tests/browser/scroll/browser_test_scroll_bounds.js b/accessible/tests/browser/scroll/browser_test_scroll_bounds.js
index 31de002cda..33a99266db 100644
--- a/accessible/tests/browser/scroll/browser_test_scroll_bounds.js
+++ b/accessible/tests/browser/scroll/browser_test_scroll_bounds.js
@@ -238,7 +238,11 @@ addAccessibleTask(
newTopBounds[0],
"x of non-fixed element remains accurate."
);
- ok(newTopBounds[1] < 0, "y coordinate shows item scrolled off page");
+ Assert.less(
+ newTopBounds[1],
+ 0,
+ "y coordinate shows item scrolled off page"
+ );
is(
origTopBounds[2],
newTopBounds[2],
@@ -254,7 +258,11 @@ addAccessibleTask(
newDBounds[0],
"x of non-fixed container element remains accurate."
);
- ok(newDBounds[1] < 0, "y coordinate shows container scrolled off page");
+ Assert.less(
+ newDBounds[1],
+ 0,
+ "y coordinate shows container scrolled off page"
+ );
// Removing the position styling on this acc causes it to be bound by
// its parent's bounding box, which alters its width as a block element.
// We don't particularly care about width in this test, so skip it.
@@ -481,7 +489,7 @@ addAccessibleTask(
newBounds[0],
`x coord of non-sticky element remains accurate.`
);
- ok(newBounds[1] < 0, "y coordinate shows item scrolled off page");
+ Assert.less(newBounds[1], 0, "y coordinate shows item scrolled off page");
// Removing the position styling on this acc causes it to be bound by
// its parent's bounding box, which alters its width as a block element.
diff --git a/accessible/tests/browser/scroll/browser_test_scroll_substring.js b/accessible/tests/browser/scroll/browser_test_scroll_substring.js
index e8426d00ca..031b8a5124 100644
--- a/accessible/tests/browser/scroll/browser_test_scroll_substring.js
+++ b/accessible/tests/browser/scroll/browser_test_scroll_substring.js
@@ -45,8 +45,9 @@ The only thing I found in the fridge was a dead dove in a bag.
text.getCharacterExtents(7, {}, objY, {}, {}, COORDTYPE_SCREEN_RELATIVE);
return objY.value;
};
- ok(
- containerHeight < getCharY(),
+ Assert.less(
+ containerHeight,
+ getCharY(),
"Character is outside of container bounds"
);
text.scrollSubstringTo(7, 8, SCROLL_TYPE_TOP_EDGE);