mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-05-22 13:32:11 +00:00
fix(test): clear toast queue after dismissing subscription dialog
The subscription bootstrap path surfaces a transient error toast in the top-right that overlaps the user popover region and intercepts clicks on the add-credits-button. Five of the new credits.spec.ts cases were failing in CI for this reason. Use the existing ToastHelper to clear any queued toasts before the test body runs.
This commit is contained in:
@@ -70,6 +70,10 @@ function createCreditsTest(
|
||||
comfyPage.page.getByTestId(TestIds.user.currentUserButton)
|
||||
).toBeVisible()
|
||||
await dismissSubscriptionDialogIfOpen(comfyPage.page)
|
||||
// The subscription bootstrap can surface a transient error toast
|
||||
// top-right that overlaps the popover region and intercepts clicks on
|
||||
// `add-credits-button`. Clear any queued toasts before yielding.
|
||||
await comfyPage.toast.closeToasts()
|
||||
await use(helper)
|
||||
await helper.clearMocks()
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user