MCP_Server_Selenium_Playwright_QA

AuTeLipi/MCP_Server_Selenium_Playwright_QA

3.2

If you are the rightful owner of MCP_Server_Selenium_Playwright_QA and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.

Unified Web Testing MCP Servers for AI-Driven Browser Automation

Tools
2
Resources
0
Prompts
0

๐Ÿค– MCP Server: Selenium + Playwright QA Automation

Unified Web Testing MCP Servers for AI-Driven Browser Automation

Testing Status AI Powered Framework

Revolutionizing QA workflows with Model Context Protocol integration

๐Ÿš€ Quick Start โ€ข ๐ŸŽฏ Features โ€ข ๐Ÿ“– Documentation โ€ข ๐Ÿค Contribute

Image


๐ŸŒ Project Overview

This project demonstrates how to orchestrate web-testing MCP (Model Context Protocol) servers (Selenium MCP and Playwright MCP) from a unified QA workspace, enabling AI agents to drive real browsers through natural language commands in modern IDEs like Cursor/VS Code or AI clients like Claude Desktop and Goose.

Why MCP for QA?

  • ๐Ÿ› ๏ธ Standardized Interface: Consistent API for AI agents across different automation frameworks
  • ๐Ÿ‘จโ€๐Ÿ’ป Developer-Centric Workflow: Transform natural language prompts into executable test code instantly
  • ๐Ÿ”„ Framework Agnostic: Seamlessly switch between Selenium and Playwright without changing your approach
  • ๐ŸŽฏ IDE Integration: Native support in modern development environments

๐ŸŽญ The Evolution of Testing

Gone are the days of writing hundreds of lines of boilerplate automation code. MCP QA Automation represents the next evolution in software testingโ€”where AI agents understand your testing intent and translate it into precise browser actions across multiple frameworks.

Image

๐ŸŒŸ What Makes Us Different?

Unlike traditional automation tools that require extensive coding knowledge, our MCP-integrated approach allows you to:

  • Speak in Plain English: Describe your test scenarios naturally
  • Instant Code Generation: Watch AI transform your ideas into executable tests
  • Cross-Framework Harmony: Seamlessly switch between Selenium and Playwright
  • Visual Intelligence: AI-powered element recognition and interaction

๐ŸŽฏ Arsenal Features

๐Ÿ”ฎ AI-Powered Test Generation

# Simply describe what you want to test
"Test the login with invalid credentials and capture the error message"
# โ†’ Generates complete test automation code

๐ŸŽจ Multi-Framework Architecture

FrameworkLanguageStrengths
Playwright ๐ŸŽญPythonModern, fast, reliable
Selenium ๐Ÿ•ธ๏ธJava & PythonIndustry standard, extensive support

๐ŸŽช Smart Test Scenarios

  • ๐Ÿ” Authentication Testing: Login/logout flows with intelligent error detection
  • ๐Ÿ“‹ Form Validation: Dynamic form testing with real-time feedback
  • ๐Ÿ“ฑ Cross-Browser Compatibility: One test, multiple browsers
  • ๐Ÿ“ธ Visual Regression: Automated screenshot comparison

๐Ÿš€ Launch Sequence

Step 1: Clone the Arsenal

git clone https://github.com/AuTeLipi/MCP_Server_Selenium_Playwright_QA.git
cd MCP_Server_Selenium_Playwright_QA

Step 2: Prepare Your Weapons

# Python Environment
pip install -r requirements.txt
playwright install

# Java Environment (for Selenium)
# Ensure Java 11+ and Maven are installed

Step 3: Configure MCP Integration

Create .cursor/mcp.json in your IDE:

{
  "mcpServers": {
    "playwright": {
      "command": "npx",
      "args": ["@playwright/mcp@latest"]
    },
    "selenium": {
      "command": "npx", 
      "args": ["-y", "@angiejones/mcp-selenium"]
    }
  }
}

Step 4: Launch Your First Mission

# Playwright Mission
python Module01_Automation_UsingPlaywright/vwo_invalid_login_test.py

# Selenium Mission  
python Module02_Automation_UsingSelenium/vwo_invalid_login_selenium.py

๐Ÿ—‚๏ธ Mission Control Structure

๐Ÿ—๏ธ MCP_Server_Selenium_Playwright_QA/
โ”œโ”€โ”€ ๐ŸŽญ Module01_Automation_UsingPlaywright/
โ”‚   โ”œโ”€โ”€ ๐ŸŽฏ vwo_invalid_login_test.py
โ”‚   โ””โ”€โ”€ ๐Ÿ“š lab_guides/
โ”œโ”€โ”€ ๐Ÿ•ธ๏ธ Module02_Automation_UsingSelenium/
โ”‚   โ”œโ”€โ”€ โ˜• Java_implementations/
โ”‚   โ”œโ”€โ”€ ๐Ÿ Python_implementations/
โ”‚   โ””โ”€โ”€ ๐Ÿ“ธ execution_screenshots/
โ”œโ”€โ”€ ๐Ÿ™ Module03_Push_Code_To_GitHub/
โ”‚   โ””โ”€โ”€ ๐Ÿ”„ integration_guides/
โ”œโ”€โ”€ โšก Module04_Generate_Automation_Script/
โ”‚   โ”œโ”€โ”€ ๐Ÿค– ai_generated_scripts/
โ”‚   โ””โ”€โ”€ ๐Ÿ“‹ templates/
โ””โ”€โ”€ โš™๏ธ Configuration/
    โ”œโ”€โ”€ mcp.json
    โ””โ”€โ”€ requirements.txt

๐Ÿงช Live Experiments

๐Ÿ”ฌ Test Case: VWO Login Validation

Objective: Validate error handling for invalid login attempts

AI Prompt: "Create a test that tries to login with wrong credentials on VWO and verifies the error message"

Generated Output:

  • โœ… Automated browser launch
  • โœ… Form interaction simulation
  • โœ… Error message capture
  • โœ… Screenshot documentation
  • โœ… Assertion validation

๐Ÿ”ฌ Test Case: iDrive360 Signup Flow

Objective: Test comprehensive signup form validation

Results:

  • ๐Ÿ“ฑ Country code selection testing
  • ๐Ÿ“ž Phone number format validation
  • โš ๏ธ Real-time error feedback capture
  • ๐Ÿ“Š Form completion analytics

๐ŸŽจ Visual Chronicles

Our tests don't just pass/failโ€”they tell stories through captured moments:

Test PhaseVisual Evidence
๐Ÿ Initial LoadClean page state capture
โŒจ๏ธ User InteractionForm filling progression
โŒ Error StatesValidation message display
๐ŸŽฏ Final ResultsSuccess/failure documentation

๐Ÿ”ง Advanced Configuration

Custom Test Data Factory

# Dynamic data generation for realistic testing
class TestDataFactory:
    @staticmethod
    def generate_invalid_credentials():
        return {
            "username": fake.email(),
            "password": fake.password(length=8),
            "expected_error": "Your email, password, IP address or location did not match"
        }

Multi-Environment Support

# environments.yml
staging:
  base_url: "https://staging.vwo.com"
  timeout: 10000
  
production:
  base_url: "https://vwo.com"
  timeout: 5000

๐Ÿค Join the Mission

For Contributors

  1. ๐Ÿด Fork the repository
  2. ๐ŸŒฟ Create a feature branch (feature/amazing-test-case)
  3. โœจ Commit your changes with descriptive messages
  4. ๐Ÿš€ Push to your branch
  5. ๐ŸŽฏ Create a Pull Request with detailed description

For Testers

  • ๐Ÿ› Report bugs with detailed reproduction steps
  • ๐Ÿ’ก Suggest new test scenarios
  • ๐Ÿ“ Improve documentation
  • ๐ŸŽจ Share creative test implementations

๐Ÿ† Hall of Fame

Created By

AuTeLipi - The Architect of Automated Excellence

Special Thanks

  • Pramod Dutta for introducing MCP and opening new horizons in test automation
  • Microsoft Playwright Team for MCP integration
  • Angie Jones for Selenium MCP development
  • The QA Community for continuous inspiration

๐Ÿ“œ License & Disclaimer

This project is licensed under the MIT License - see the file for details.

Built with โค๏ธ for the QA community. May your tests be green and your bugs be few.


Ready to revolutionize your testing workflow?

Star this repo Follow for updates

The future of testing is here. Are you ready to embrace it?