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:
Glary-Bot
2026-05-11 19:33:35 +00:00
parent fde30c2b4f
commit 9b4612c67b

View File

@@ -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()
},