test(desktop): await compact preview geometry

Co-authored-by: Taylor Ho <taylorkmho@gmail.com>
Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
This commit is contained in:
npub1223z34hd7vtwc6qj4s7flsxkj644nlre2nthu7lrrmkumhu3xddsrx9r6w
2026-07-30 23:21:05 -07:00
co-authored by Taylor Ho
parent 7d0705ed80
commit ff3a54fbbb
+5
View File
@@ -462,6 +462,11 @@ test("link preview no-image collapse restores the compact card", async ({
.locator('[data-link-preview="github-pull-request"]');
await expect(card).toHaveAttribute("data-image-state", "pending");
await expect(card).toBeVisible();
await expect
.poll(() =>
card.evaluate((element) => element.getBoundingClientRect().height),
)
.toBe(80);
const pending = await card.evaluate((element) => ({
height: element.getBoundingClientRect().height,
textLeft: element