e2e-panther-playwright — Claude Code skill: E2E tests and setup
The e2e-panther-playwright skill guides Symfony E2E tests with Panther for browser flows and Playwright for more involved cases. Use it when JavaScript behavior is beyond what WebTestCase can observe.
MIT ★ 234 updated 2026-10-05
npx skills add dev-toolings/superpowers-symfony --skill e2e-panther-playwright -a claude-codeWhat e2e-panther-playwright does
The skill chooses static::createPantherClient() for a real-browser flow and static::createClient() when JavaScript is not involved. It calls for explicit waits such as waitFor() and assertions about elements that should appear later. For selectors, it favors data-testid over styling classes. E2E files belong in tests/E2E, with the database reset between tests.
Panther setup uses symfony/panther and dbrekelmans/bdi; run vendor/bin/bdi detect drivers and register ServerExtension in phpunit.dist.xml. For complex browser scenarios, the skill points to running Playwright separately. It also gives debugging settings: PANTHER_NO_HEADLESS=1 with --debug, and PANTHER_NO_SANDBOX=1 in CI.
E2E tests run slowly, so the skill recommends covering critical paths and keeping them apart from unit tests. Remove screenshots created by takeScreenshot() or PANTHER_ERROR_SCREENSHOT_DIR instead of committing them.
What it helps with
- test JavaScript behavior in a real browser
- cover a user journey across several pages
- wait for an element or expected text
- investigate a browser test that fails in CI
- keep critical E2E checks separate from unit tests
Example prompts for the agent
- Write a Symfony E2E test for a JavaScript login flow using Panther.
- Test a multi-page checkout journey and add explicit waits.
- Help debug a Panther test failure in CI and check the driver setup.
How to install e2e-panther-playwright
1Skills CLI (Vercel)
npx skills add dev-toolings/superpowers-symfony --skill e2e-panther-playwright -a claude-code2Manually: put the files in place
~/.claude/skills/e2e-panther-playwright/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/e2e-panther-playwright/
1Skills CLI (Vercel)
npx skills add dev-toolings/superpowers-symfony --skill e2e-panther-playwright -a codex2Manually: put the files in place
.agents/skills/e2e-panther-playwright/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add dev-toolings/superpowers-symfony --skill e2e-panther-playwright -a cursor2Manually: put the files in place
.cursor/skills/e2e-panther-playwright/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install dev-toolings/superpowers-symfony content/skills/e2e-panther-playwright2Manually: put the files in place
.github/skills/e2e-panther-playwright/SKILL.md1Skills CLI (Vercel)
npx skills add dev-toolings/superpowers-symfony --skill e2e-panther-playwright -a gemini-cli2Platform CLI
gemini skills install https://github.com/dev-toolings/superpowers-symfony --path content/skills/e2e-panther-playwrightManually: put the files in place
.devin/skills/e2e-panther-playwright/SKILL.mdThe legacy .windsurf/skills/ path still works
Claude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about e2e-panther-playwright
How do I install e2e-panther-playwright in Claude Code?
Run npx skills add dev-toolings/superpowers-symfony --skill e2e-panther-playwright -a claude-code. The skill file is at ~/.claude/skills/e2e-panther-playwright/SKILL.md.
What does e2e-panther-playwright do?
It guides Symfony E2E tests using Panther for browser flows and Playwright for complex cases. It also covers waits, debugging, and where to keep the tests.
What do I need to set up Panther tests?
Install symfony/panther and dbrekelmans/bdi, run vendor/bin/bdi detect drivers, then register ServerExtension in phpunit.dist.xml.
Source text
SKILL.md · MIT
--- name: e2e-panther-playwright description: Write end-to-end tests with Symfony Panther 2.4 for browser automation or Playwright for complex scenarios capabilities: [read, search] tags: [testing] # projected by `bun run build` — do not edit by hand allowed-tools: - Read - Glob - Grep --- # E2e Panther Playwright (Symfony) ## Use when - A flow needs a real browser: JavaScript, multi-page journeys such as login, checkout or signup. - `WebTestCase` cannot see the behavior because it depends on client-side rendering. - Cross-browser needs (WebKit, tracing, video) that WebDriver does not cover: run Playwright separately. - Debugging a browser test that fails only in CI. ## Default workflow 1. Pick the client: `static::createPantherClient()` for a real browser, `static::createClient()` when no JavaScript is needed. 2. Install `symfony/panther` and `dbrekelmans/bdi`, run `vendor/bin/bdi detect drivers`, and register `ServerExtension` in `phpunit.dist.xml`. 3. Extend `PantherTestCase` and drive the flow with explicit waits: `waitFor()`, `waitForVisibility()`, `waitForElementToContain()`. 4. Assert future state with `assertSelectorWillExist()` or `assertSelectorWillContain()`, current state with `assertSelectorIsVisible()`. 5. Keep the suite in `tests/E2E` and reset the database between tests (DAMADoctrineTestBundle or Foundry). 6. Debug with `PANTHER_NO_HEADLESS=1` and `--debug`; set `PANTHER_NO_SANDBOX=1` in CI. ## Guardrails - Never rely on implicit timing: every async step gets a `waitFor*` or an `assertSelectorWill*`. - Target `data-testid` attributes, not styling classes. - Delete the PNGs written by `takeScreenshot()` or `PANTHER_ERROR_SCREENSHOT_DIR`; never commit them. - E2E is slow: cover critical paths only and keep it apart from unit tests. ## Progressive disclosure - Use this file for execution posture and risk controls. - Open references when deep implementation details are needed. ## Output contract - E2E test files, with the client type and the wait strategy used. - Driver setup, `ServerExtension` registration and the `PANTHER_*` variables needed locally and in CI. - Confirmation that screenshots were cleaned up. ## References - `reference.md`
© dev-toolings · MIT · dev-toolings/superpowers-symfony