mcpField
P
Playwright MCP Project

Playwright MCP Project

Local
github.com/vikaskumarprofessional92Browser Automation0Updated 82w ago

About Playwright MCP Project

A test project demonstrating Playwright MCP server usage with a Jenkins pipeline. It includes a browser test and pipeline configuration to install dependencies, run tests, and publish reports.

Key features

  1. 01Playwright browser tests
  2. 02Jenkins pipeline configuration
  3. 03Dependency installation and test runs
  4. 04Test report generation and publishing

Use cases

  1. 01Run the example browser navigation test
  2. 02Execute tests through a Jenkins pipeline
  3. 03Generate and publish test reports

MCP support

The project demonstrates configuring a Playwright MCP server, including enabling the `--vision` option for `@playwright/mcp@latest` in `settings.json`.

Configuration

Local server config is the same for every client. Copy it into your client’s MCP config file.

mcp.json · Universal config
{
"mcpServers": {
"playwright-mcp-project": {
"command": "npx",
"args": [
"-y",
"@playwright/mcp"
]
}
}
}
Run commandnpx -y @playwright/mcp

Local servers need a runtime on your machine (e.g. Node.js 18+). Config file locations differ by client; see your client’s docs.

Packages
npm@playwright/mcp

Tools

30

Saved tool list · updated 3w ago

This tool takes no parameters.

Details

From the project README

Playwright MCP Project

A project to demonstrate Playwright MCP server usage with Jenkins pipeline.

Prerequisites

  • Node.js installed on your machine.
  • npm (Node Package Manager) comes with Node.js.

Installation

  1. Clone the repository:

    git clone https://github.com/vikaskumarprofessional92/playwright-mcp-project.git
    cd playwright-mcp-project
    
  2. Install the dependencies:

    npm install
    
  3. Set up the Playwright MCP server:

    • Ensure you have the MCP server configured in your settings.json as follows:
      {
        "mcpServers": {
          "playwright": {
            "command": "npx",
            "args": [
              "@playwright/mcp@latest",
              "--vision"
            ]
          }
        }
      }
      

Running Tests

To run the tests, use the following command:

npx playwright test

Test Specifications

The test specifications can be found in the src/tests/example.spec.ts file. This file contains a test suite that includes a test case for opening a browser and navigating to the Google.ca website.

Jenkins Integration

This project includes Jenkins pipeline configuration for continuous integration. The pipeline is configured to:

  • Install dependencies
  • Run tests
  • Generate and publish test reports

License

This project is licensed under the MIT License.

Comments

Markdown supported

New to MCP?

From what the protocol is to installing your first server, these answers cover most first questions.

An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.