Skip to content
RED SAGSkills
medium10 pts · first answer countsplaywrightflaky-tests

Flaky Playwright visibility check

This Playwright test sometimes fails because the toast appears a moment after the click. What is the best fix?

await page.getByRole('button', { name: 'Save' }).click()
expect(await page.locator('.toast-success').isVisible()).toBe(true)
Choose one answer

Discussion 0

Join free to post in the discussion.

Related questions