Skip to content

Commit aafe0b0

Browse files
test(web): the Add ChatGPT account test waits for the dialog to leave the DOM
Co-Authored-By: Claude Opus 5.5 <[email protected]>
1 parent a89c540 commit aafe0b0

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

‎apps/web/src/components/settings/AddCodexAccountDialog.browser.test.tsx‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,7 @@ describe("AddCodexAccountDialog", () => {
124124
for (const animation of document.getAnimations()) animation.finish();
125125
});
126126
await vi.waitFor(() => expect(onClose).toHaveBeenCalledTimes(1));
127-
expect(page.getByRole("dialog").query()).toBeNull();
127+
// onClose runs before the owner's unmount commits, so wait for the dialog to leave the DOM.
128+
await expect.element(page.getByRole("dialog")).not.toBeInTheDocument();
128129
});
129130
});

0 commit comments

Comments
 (0)