Playwright Pro — Fix
Fix flaky and failing Playwright tests with root cause analysis.
$skillfish add ~skills/playwright-pro-fix Real Conversations
See how the Playwright Pro — Fix skill responds to actual requests. These are representative examples of what your AI agent will produce.
Our checkout.spec.ts passes locally every time but fails in CI about 60% of the time. The error is expect(page.getByText('Order confirmed')).toBeVisible() timing out after 5000ms. We're on GitHub Actions ubuntu-latest.
This is a classic Environment category flaky test — the order confirmation page takes longer on GitHub Actions' slower runners than on your local machine.
This skill includes executable scripts — I'll need your permission before running them.
Capturing a trace to confirm:
npx playwright test checkout.spec.ts --trace=on --retries=0
Root cause: Default 5000ms timeout is too tight for CI. The fix is not a longer timeout — it's waiting for the right signal.
Fix — wait for the API response, then assert:
// BEFORE (times out in CI)
await expect(page.getByText('Order confirmed')).toBeVisible();
// AFTER (waits for API response first)
await page.waitForResponse(resp =>
resp.url().includes('/api/orders') && resp.status() === 201
);
await expect(page.getByText('Order confirmed')).toBeVisible();
Verification — burn-in 10 runs:
npx playwright test checkout.spec.ts --repeat-each=10 --reporter=list
All 10 must pass before shipping. I'll also add retries: 2 to your CI config if not already set.
Shall I apply the fix?
Get Started
How to install and use this skill in your preferred environment.
Skills are designed for AI coding agents (Claude Code, Cursor, Windsurf) and IDE-based workflows where the agent can read files, run scripts, and act on your codebase. Web-based AI can use the knowledge and frameworks, but won't have tool access.
Models & Context
Which AI models and context windows work best with this skill.
Recommended Models
Larger models produce more detailed, production-ready outputs.
Context Window
This skill's SKILL.md is typically 3–10 KB — fits in any modern context window.
All current frontier models (Claude, GPT, Gemini) support 100K+ context. Use the full window for complex multi-service work.
Pro tips for best results
Be specific
Include numbers — users, budget, RPS — so the skill can size the architecture.
Share constraints
Compliance needs, team size, and existing stack all improve the output.
Iterate
Start with a high-level design, then ask follow-ups for IaC, cost analysis, or security review.
Combine skills
Pair with companion skills below for end-to-end coverage.
Ready to try Playwright Pro — Fix?
Install the skill and start getting expert-level guidance in your workflow — any agent, any IDE.
$skillfish add ~skills/playwright-pro-fix