playwright
Skill1 starsChanged 2 months agoMITView on GitHub
Run Playwright browser tests as part of Vera's QA sign-off. Detects setup, installs if absent, writes smoke tests from the actual app structure if none exist, runs them, reports results. Called by Vera before every sign-off on any web application — not optional.
- Installs packages
94 other projects use a version of this.
Adopted by
Most recently taken up by
- Pamir-AI/skillstheir own version, first seen Nov 8, 2026
- shetengteng/skillix-hubtheir own version, first seen Nov 8, 2026
- LuisSambrano/antigravity-configtheir own version, first seen Nov 8, 2026
- fmind/dottheir own version, first seen Nov 8, 2026
- fmind/dotfilestheir own version, first seen Nov 8, 2026
- miminashi/pvesetheir own version, first seen Nov 4, 2026
Used with
Projects with it also use develop-web-game, msw and 10 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
hebertzhuSkilldevelop-web-game
Use when building or iterating on a web game and you need a tight implement-test-observe loop; prefer the bundled Playwright client, inspect screenshots and text state, and validate every meaningful change before moving on.
Also in 4 projects that use this
thongdn-itSkillmsw
MSW (Mock Service Worker) best practices for API mocking in tests (formerly test-msw). This skill should be used when setting up MSW, writing request handlers, or mocking HTTP APIs. This skill does NOT cover general testing patterns (use test-vitest or test-tdd skills) or test methodology.
Also in 3 projects that use this
SupabaseSkillreact-hook-form
Correct React Hook Form usage anywhere in the monorepo — data flow, subscriptions,
Also in 3 projects that use this
thongdn-itSkilltailwind
Tailwind CSS v4 performance optimization and best practices guidelines (formerly tailwindcss-v4-style). This skill should be used when writing, reviewing, or refactoring Tailwind CSS v4 code to ensure optimal build performance, minimal CSS output, and correct usage of v4 features. Triggers on tasks involving Tailwind configuration, @theme directive, utility classes, responsive design, dark mode, container queries, or CSS generation optimization.
Also in 5 projects that use this
VercelSkillreact
React renderer for json-render that turns JSON specs into React components. Use when working with @json-render/react, building React UIs from JSON, creating component catalogs, or rendering AI-generated specs.
Also in 6 projects that use this
OpenAISkillweb-perf
Analyzes web performance using Chrome DevTools MCP. Measures Core Web Vitals (FCP, LCP, TBT, CLS, Speed Index), identifies render-blocking resources, network dependency chains, layout shifts, caching issues, and accessibility gaps. Use when asked to audit, profile, debug, or optimize page load performance, Lighthouse scores, or site speed. Biases towards retrieval from current documentation over pre-trained knowledge.
Also in 5 projects that use this
- +1 more from thongdn-it
Other versions94 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 94
- openai/openai-agents-python★ 31ksame name
- openai/skills★ 27ksame name
- prowler-cloud/prowler★ 15ksame name
- hyperdxio/hyperdx★ 10ksame name
- bluesky-social/atproto★ 9.7ksame name
- netease-youdao/LobsterAI★ 6.2ksame name
- Kiln-AI/Kiln★ 5.3ksame name
- freestylefly/wesight★ 969same name
- Gram-ax/gramax★ 609same name
- JetBrains/skills★ 386same name
84 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository33 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- .github/copilot-instructions.mdCopilot instructions
- decideSkill
- deliverSkill
- researchSkill
- sprintSkill
- superteam-coachSkill
- superteam-coachSkill
- azure-ai-foundry-devSkill
- azure-devopsSkill
- bc-mcpSkill
- copilot-studio-buildSkill
- decideSkill
- deliverSkill
- erp-connectorsSkill
- fabric-appsSkill
- fabric-medallionSkill
- fabric-notebooksSkill
- fabric-onelakeSkill
- fabric-power-biSkill
- find-skillsSkill
- mirrorSkill
- ontologySkill
- researchSkill
- sap-btp-agentsSkill
- semantic-reasoningSkill
- semantic-searchSkill
- sprintSkill
- superteam-coachSkill
- superteam-demoSkill
- systematic-debuggingSkill
- test-driven-developmentSkill
The file
We split this skill into the rules it gives an agent
11 rules. 0 are common, 6 are distinctive, and 5 are very specific to this project.
0
Common
Most of the 81 edited versions we read keep these.
6
Distinctive
This author's own choices. Worth a look.
5
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- could be automatic: a setting could enforce it
- Distinctive: line 17
Check whether the dev server is running:
- Very specific: line 23
If not running: start it in background (npm run dev / pnpm dev / pnpm dev:ui), wait for the port to respond, then continue.
- Very specific: line 41
If no
playwright.config.jsexists,: create it — use the fde-demos-worlds pattern exactly: - Very specific: line 68
If tests/ has no .spec.js or .spec.ts files, read the actual app source and generate tests/smoke.spec.js.
- Distinctive: line 125
If tests fail due to timing on first run, retry once:
- Distinctive: line 130
Do not retry more than once.
- Distinctive: line 142
Check the browser console — zero errors (F12 → Console)
- Distinctive: line 143
Check the Network tab — zero failed requests (red rows)
- Distinctive: line 146
Document each item: what you did, what you saw.
- Very specific: line 182
Write tests from the actual source: Read the router and components before writing smoke.spec.js.
- Very specific: line 191
After reporting to Vera, write .squad/playwright-results.md with this format:
“Common” is measured: kept by at least 6 in 10 of the 81 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
/playwright — Browser Test Runner
You are running browser tests on behalf of Vera. The code review is already done. This step is the proof — the running application in a real browser, exercising real flows, catching what code reading never will.
Reference implementation: fde-demos-worlds — playwright.config.js + tests/shell.spec.js. When in doubt, follow that pattern.
Step 1 — Confirm Live Server
Check whether the dev server is running:
curl -s -o /dev/null -w "%{http_code}" http://localhost:5173/ 2>/dev/null
# or whichever port this project uses (3000, 4321, etc.)If not running: start it in background (npm run dev / pnpm dev / pnpm dev:ui), wait for the port to respond, then continue. Do not proceed without a live server — a 000 or connection refused means every test will fail silently.
Step 2 — Check Playwright Setup
npx playwright --version 2>/dev/null || echo "NOT_INSTALLED"
ls playwright.config.js playwright.config.ts 2>/dev/null || echo "NO_CONFIG"
ls tests/*.spec.* 2>/dev/null || echo "NO_TESTS"If Playwright is not installed:
npm install -D @playwright/test
npx playwright install chromiumIf no playwright.config.js exists, create it — use the fde-demos-worlds pattern exactly:
import { defineConfig } from '@playwright/test';
export default defineConfig({
testDir: './tests',
timeout: 30000,
use: {
baseURL: 'http://localhost:[PORT]',
headless: true,
viewport: { width: 1440, height: 900 },
},
webServer: {
command: '[DEV_COMMAND]',
url: 'http://localhost:[PORT]',
reuseExistingServer: true,
timeout: 30000,
},
});Fill in [PORT] and [DEV_COMMAND] from the project's package.json scripts.
Step 3 — Write Smoke Tests (if none exist)
If tests/ has no .spec.js or .spec.ts files, read the actual app source and generate tests/smoke.spec.js.
Read before writing:
src/App.tsxorsrc/main.tsx— find all routes- Component files for each route — find key UI elements (headings, buttons, forms, cards)
package.json— confirm dev server command and port
Test structure — follow this pattern exactly (from fde-demos-worlds):
import { test, expect } from '@playwright/test';
// One test per route — minimum
test('[page name] loads — [key elements] visible', async ({ page }) => {
await page.goto('/[route]');
// Confirm the page actually rendered something meaningful
await expect(page.locator('[specific visible element]')).toBeVisible();
await expect(page.locator('[another key element]')).toBeVisible();
});
// Navigation flows — test that clicking things goes where expected
test('[flow name] — click [element] navigates to [route]', async ({ page }) => {
await page.goto('/');
await page.locator('[selector]').click();
await expect(page).toHaveURL('/[expected-route]');
await expect(page.locator('[element that proves the page loaded]')).toBeVisible();
});
// Form interactions — test enable/disable state, validation
test('[form name] — [button] disabled when [condition]', async ({ page }) => {
await page.goto('/[route]');
await expect(page.locator('button', { hasText: '[button text]' })).toBeDisabled();
});
// Content integrity — no markdown leaking, no raw tokens
test('[page] — no raw markdown markers in rendered output', async ({ page }) => {
await page.goto('/[route]', { waitUntil: 'networkidle' });
const bodyText = await page.locator('body').innerText();
expect(bodyText).not.toContain('###');
expect(bodyText).not.toMatch(/^##\s/m);
expect(bodyText.trim().length).toBeGreaterThan(50);
});Use exact text locators over CSS selectors where possible — page.locator('text=Start demo (English)') is more resilient than page.locator('.card .btn'). The fde-demos-worlds tests do this correctly.
Minimum test count: one test per route, one per significant interactive flow. Do not write tests you cannot verify against the running app — generic tests create false confidence.
Step 4 — Run Tests
npx playwright test --reporter=list 2>&1If tests fail due to timing on first run, retry once:
npx playwright test --reporter=list --retries=1 2>&1Do not retry more than once. Flaky is a signal, not a nuisance.
Capture full output: test names, pass/fail, error messages, line numbers on failures.
Step 5 — Manual Golden Path (always, even if all tests pass)
Automated tests cover routes that were already written into tests. The golden path covers what was just built. For every new feature in this delivery:
- Navigate to it in the browser
- Complete the primary action the user would take
- Check the browser console — zero errors (F12 → Console)
- Check the Network tab — zero failed requests (red rows)
- Try one edge case: empty input, wrong value, fast click
Document each item: what you did, what you saw.
Step 6 — Report to Vera
PLAYWRIGHT REPORT
Date: YYYY-MM-DD
App: [name] at http://localhost:[PORT]
Tests: [N] run | [N] passed | [N] failed
Results:
✓ [test name]
✓ [test name]
✗ [test name] — [exact error message and line]
Console errors on golden path: [none / list]
Network failures on golden path: [none / list]
Manual golden path:
✓ [what you did — what happened]
✓ [what you did — what happened]
✗ [what you did — what failed]
Playwright verdict: PASS / FAIL / PARTIAL
[One sentence on overall state]A FAIL here is a Vera BLOCKED. Code that reads correctly but fails in the browser has not been delivered.
Non-Negotiables
- No running server = no Playwright run = BLOCKER. Flag it. Do not approximate.
- Write tests from the actual source. Read the router and components before writing
smoke.spec.js. Tests guessed from nothing create false confidence — worse than no tests. - Console errors are failures. A page that renders but throws errors is broken.
- The golden path is not optional even if all tests pass. New features aren't in tests yet. Manual verification is the only proof for new code.
- This skill is called by Vera before every sign-off on any web app. Not sometimes. Not on big deliveries. Every time.
Step 7 — Write Playwright Sentinel
After reporting to Vera, write .squad/playwright-results.md with this format:
PLAYWRIGHT RESULTS — YYYY-MM-DD
Tests: [N] run | [N] passed | [N] failed
Console errors: [none / list]
Network failures: [none / list]
Golden path: [pass / fail]Fill values from the Step 6 report. File presence (not content) is what the push gate checks — but write accurate content for Coach. Without this file, H2 in pre-push-vera.ps1 blocks the push on any project with playwright.config.*.
/deliver Step 4 deletes .squad/playwright-results.md as part of sentinel cleanup.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

