From fd6d0be50fe6e858315d9dea56bfc82af646c7bb Mon Sep 17 00:00:00 2001 From: Calixte Denizet Date: Wed, 3 Jul 2024 09:57:12 +0200 Subject: [PATCH] Make sure the editor is visible before getting its rect --- test/integration/test_utils.mjs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/integration/test_utils.mjs b/test/integration/test_utils.mjs index c49cb1daa..4e7d28e00 100644 --- a/test/integration/test_utils.mjs +++ b/test/integration/test_utils.mjs @@ -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 };