MCP Playwright Test

by w1561778301

1 stars
265 downloads
Not rated
GitHub

About

A Model Context Protocol (MCP) server for automating Playwright tests

Details

Author
w1561778301
GitHub stars
1
Downloads
265
Categories
Automation

- Clones Git repositories or uses local projects for testing
- Launches browsers (Chromium, configurable) with headless mode
- Generates test cases from natural language requirements
- Executes both UI and API test suites
- Captures network requests and console logs
- Supports OpenAPI 3.0, Swagger 2.0, and Apifox API specs
- Provides test execution reports and test case resources
- Configurable via environment variables or .playwright-mcp.json

Setting up with Highlight

This MCP is not yet compatible with Highlight’s one-click setup. However, you can still use it with Highlight by following these steps:

  1. Download and install Highlight from highlightai.com/download
  2. Navigate to the plugins tab and select "Add Custom Plugin"
  3. Configure the plugin with the settings below
    Plugin Name MCP Playwright Test
    Command (node, npx, python, etc.)

    Please refer to the README for specific instructions on how to obtain API keys or other required environment variables.

  4. Enable "Start Automatically" if you want the plugin to start when Highlight launches

From the repository

Install via npm/yarn/pnpm (npm install mcp-playwright-test). Set the required ANTHROPIC_API_KEY environment variable (for test case generation). Start the server with npm run start or npx ts-node src/test-mcp.ts. Configure via .playwright-mcp.json for integration with Claude Desktop and Cursor.

Claude Desktop / Cursor

Paste into your MCP client config file to install this server.

{
    "mcpServers": {
        "mcp playwright test": {
            "mcp-playwright-test": {
                "command": "npx",
                "args": [
                    "ts-node",
                    "src/test-mcp.ts"
                ]
            }
        }
    }
}

McpServers

{
    "mcp-playwright-test": {
        "command": "npx",
        "args": [
            "ts-node",
            "src/test-mcp.ts"
        ]
    }
}

MCP Playwright Test

基于 Model Context Protocol (MCP)的 Playwright 测试自动化服务器。

功能特点

- 自动获取项目代码(支持 Git 仓库或本地项目)
- 使用 Playwright 设置测试环境
- 基于需求生成测试用例
- 执行 UI 和 API 测试并生成详细报告
- 捕获并分析网络请求和控制台日志

mcphub

快速开始

安装

```bash

No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.