Skip to content
Skillpedia
Testing40k · #5272

playwright-generate-test

Helps your agent create tests for a website. It's useful when you need to check if a website works as expected. This ensures the website functions well for users.

What it does

This tool creates automatic test code for a website. You describe what you want to test, and it generates the code to check if the website works as expected.

When to use it

  • ✓When you want to verify if a new website feature is working.
  • ✓When you need to ensure a website still works after an update.
  • ✓When you need to test the same process across different browsers.

Example of what to ask your AI

“Generate a test to verify that I can add an item to the shopping cart and complete the purchase.”

Want more? Open the sections below.

How to use

The easiest way: copy the message below and paste it into Claude, ChatGPT, Cursor or any AI. It reads the skill and follows the instructions.

Skill link

https://github.com/github/awesome-copilot/blob/main/skills/playwright-generate-test/SKILL.md

Ready-to-paste message

Use this skill to help me: https://github.com/github/awesome-copilot/blob/main/skills/playwright-generate-test/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
How it works

The tool follows your instructions step-by-step using a system called Playwright MCP. It observes the website, simulates your actions, and only then writes the test code.

Installation

Easiest way: copy the skill link and paste it into Claude, ChatGPT or Cursor asking it to follow the instructions.

In the terminal (Claude Code, Codex, Cursor), in your project folder:

npx skills add github/awesome-copilot --skill playwright-generate-test

Or download just the file:

curl -L https://raw.githubusercontent.com/github/awesome-copilot/main/skills/playwright-generate-test/SKILL.md -o SKILL.md
Technical content (original SKILL.md)

Original text by the author, straight from GitHub.

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
FAQ

What is Playwright?

Playwright is a tool that allows you to create and run automated tests for websites.

What is an automated test?

It's a script that simulates a user interacting with a website to check if everything is working correctly, without a person needing to do it manually.

What happens if I don't provide a scenario?

The tool will ask you to describe what you want to test on the website.

Details

Original description by the author

Generate a Playwright test based on a scenario using Playwright MCP

repo: github/awesome-copilot

Popularity

GitHub stars
40k
Ranking position
#5272
License
MIT
Updated
10/15/2026

Is this skill useful?

0

Sign in to vote.

Comments

  • …

More skills from this repository

Similar skills