playwright-generate-test — GitHub Copilot skill
Generates a Playwright test from a scenario through Playwright MCP. Use it when the browser flow should be completed before test code is written.
npx skills add github/awesome-copilot --skill playwright-generate-testWhat playwright-generate-test does
The skill takes a scenario and performs the prescribed steps one at a time with Playwright MCP tools. If no scenario is provided, the agent asks for one. It does not produce test code before those steps are complete.
After the flow is complete, it writes a TypeScript test using @playwright/test from the message history. The generated file goes into the tests directory.
The agent then runs the file and revises it until the test passes. Install it for browser scenarios that need to be exercised first; skip it when you only want an unexecuted test stub.
What it helps with
- generate a Playwright test from a scenario
- ask for a missing test scenario
- save the generated file in
tests - run and revise a test until it passes
Example prompts for the agent
- “Generate a test for the sign-in scenario.”
- “Walk through the checkout scenario and create a Playwright test.”
- “Use Playwright MCP to test this browser flow, then save the test.”
How to install playwright-generate-test
1Skills CLI (Vercel)
npx skills add github/awesome-copilot --skill playwright-generate-test2GitHub CLI
gh skill install github/awesome-copilot playwright-generate-test3Manually: put the files in place
.github/skills/playwright-generate-test/SKILL.md1Skills CLI (Vercel)
npx skills add github/awesome-copilot --skill playwright-generate-test -a claude-code2Manually: put the files in place
~/.claude/skills/playwright-generate-test/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/playwright-generate-test/
Manually: put the files in place
.agents/skills/playwright-generate-test/SKILL.mdFor all projects use ~/.agents/skills/
Manually: put the files in place
.cursor/skills/playwright-generate-test/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
Platform CLI
gemini skills install https://github.com/github/awesome-copilot --path skills/playwright-generate-testManually: put the files in place
.devin/skills/playwright-generate-test/SKILL.mdThe legacy .windsurf/skills/ path still works
Claude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
From the same set554
The whole set →Similar
Questions about playwright-generate-test
How do I install playwright-generate-test in GitHub Copilot?
Run npx skills add github/awesome-copilot --skill playwright-generate-test. You can also use gh skill install github/awesome-copilot playwright-generate-test.
What does playwright-generate-test do?
It works through a scenario with Playwright MCP tools, then creates a TypeScript test with @playwright/test. The skill saves the file in tests and runs it for revisions.
Where does playwright-generate-test save the generated test?
It saves the generated test file in the tests directory.
Source text
SKILL.md · MIT
--- name: playwright-generate-test description: 'Generate a Playwright test based on a scenario using Playwright MCP' --- # Test Generation with Playwright MCP Your goal is to generate a Playwright test based on the provided scenario after completing all prescribed steps. ## Specific Instructions - You are given a scenario, and you need to generate a playwright test for it. If the user does not provide a scenario, you will ask them to provide one. - DO NOT generate test code prematurely or based solely on the scenario without completing all prescribed steps. - DO run steps one by one using the tools provided by the Playwright MCP. - Only after all steps are completed, emit a Playwright TypeScript test that uses `@playwright/test` based on message history - Save generated test file in the tests directory - Execute the test file and iterate until the test passes
© github · MIT · github/awesome-copilot