DEV Community

Matias Aguirre
Matias Aguirre

Posted on

I Built an E2E Test Runner Where Tests Are JSON, Not Code

The Problem

Writing E2E tests shouldn't require a testing framework, complex setup, or JavaScript files. QA
engineers, product managers, and devs should all be able to define what to test.

The Solution

@matware/e2e-runner lets you define browser tests as
simple JSON action arrays:

  [
    {
      "name": "login-flow",
      "actions": [
        { "type": "goto", "value": "/login" },
        { "type": "type", "selector": "#email", "value": "user@test.com" },
        { "type": "type", "selector": "#password", "value": "secret" },
        { "type": "click", "text": "Sign In" },
        { "type": "assert_text", "text": "Welcome back" }
      ]
    }
  ]
Enter fullscreen mode Exit fullscreen mode

Tests run in parallel against a Chrome pool (browserless/chrome in Docker). No Playwright config, no
Cypress dashboard, no test framework boilerplate.

Features

  • Parallel execution with configurable concurrency
  • Retries for flaky tests (with per-test override)
  • Before/After hooks at suite and global level
  • Environment profiles (staging, production, etc.)
  • JUnit XML output for CI/CD
  • Error screenshots captured automatically

The AI-native part

It includes a built-in MCP server. One command and Claude Code can run your tests as native tools:

claude mcp add --transport stdio --scope user e2e-runner \
    -- npx -y -p @matware/e2e-runner e2e-runner-mcp
Enter fullscreen mode Exit fullscreen mode

Then just ask Claude:

  • "Run all E2E tests"
  • "Create a test that verifies the checkout flow"
  • "What's the status of the Chrome pool?"

Claude picks the right tool automatically. No prompting tricks needed.

Get Started

  npm install @matware/e2e-runner
  npx e2e-runner init
  npx e2e-runner pool start
  npx e2e-runner run --all
Enter fullscreen mode Exit fullscreen mode

GitHub: https://github.com/fastslack/mtw-e2e-runner
npm: https://www.npmjs.com/package/@matware/e2e-runner

Feedback welcome!

Top comments (0)