Skip to content

Commit

Permalink
Merge pull request #18374 from calixteman/test_editor_visible
Browse files Browse the repository at this point in the history
Make sure the editor is visible before getting its rect
  • Loading branch information
timvandermeij authored Jul 4, 2024
2 parents 944f3ac + fd6d0be commit 03a0500
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/integration/test_utils.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ function getSelector(id) {
async function getRect(page, selector) {
// In Chrome something is wrong when serializing a `DomRect`,
// so we extract the values and return them ourselves.
await page.waitForSelector(selector);
await page.waitForSelector(selector, { visible: true });
return page.$eval(selector, el => {
const { x, y, width, height } = el.getBoundingClientRect();
return { x, y, width, height };
Expand Down

0 comments on commit 03a0500

Please sign in to comment.