Skip to content

Commit 512860f

Browse files
committed
Make Cowork mobile browser test portable
Signed-off-by: Joseph Yaksich <gitcommit90@users.noreply.github.com>
1 parent 3db312b commit 512860f

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

test/cowork-browser.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ test("Cowork, Files, Quick Note, Markdown, and mobile continuity work as one fil
225225
assert.ok(Math.abs(mobile.shellBottom - mobile.viewport) <= 1 && mobile.cssHeight.endsWith("px"), JSON.stringify(mobile));
226226
await page.click('[aria-label="Open navigation"]');
227227
await page.waitForSelector('[data-sidebar="mobile"] [aria-label="Open settings"]');
228-
await page.click('[data-sidebar="mobile"] [aria-label="Open settings"]');
228+
await page.evaluate(() => document.querySelector('[data-sidebar="mobile"] [aria-label="Open settings"]')?.click());
229229
await page.waitForSelector('[aria-label="Settings sections"]');
230230
const settings = await page.$eval('[aria-label="Settings sections"]', (nav) => ({ height: nav.getBoundingClientRect().height, width: nav.getBoundingClientRect().width, scrolls: nav.scrollWidth > nav.clientWidth }));
231231
assert.ok(settings.height < 90 && settings.width >= 380 && settings.scrolls, JSON.stringify(settings));

0 commit comments

Comments
 (0)