Skip to main content
Glama
hubertgajewski

playwright-report-mcp

run_tests

Run Playwright tests with filters, retries, and tracing, returning structured results to diagnose failures.

Instructions

Run Playwright tests and return structured results.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
envNoEnvironment variable overrides for the Playwright child process. Each key must be listed in PW_ALLOWED_ENV. Dangerous names (NODE_*, NPM_CONFIG_*, PATH, proxies, secrets) are always rejected. Values are never echoed in get_run_status.
tagNoTag filter, e.g. @smoke or @regression
specNoSpec file path, e.g. tests/navigation.spec.ts
waitNoWait for completion before returning. Defaults to true. Set false to start a background run and poll it with get_run_status.
traceNoForce Playwright tracing mode, overriding playwright.config.ts.
headedNoRun with a visible browser window. Omitting or setting false leaves playwright.config.ts intact — Playwright has no --no-headed flag, so false does not force headless when the config sets headed.
browserNo
retriesNoMaximum retry count for flaky tests; 0 disables retries.
timeoutNoTimeout in milliseconds for the whole test run. Defaults to 300000.
workersNoNumber of parallel workers (positive integer).
maxFailuresNoStop the run after this many failures.
updateSnapshotsNoUpdate snapshot baselines. Playwright default is "missing"; "changed" updates differing + missing.
workingDirectoryNoPlaywright project directory. Absolute or relative to the MCP server launch directory. Defaults to ".". Must be under PW_ALLOWED_DIRS.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv3.4.0
    • addedInput schema / properties / env
      Added value: +{
      +  "additionalProperties": {
      +    "type": "string"
      +  },
      +  "description": "Environment variable overrides for the Playwright child process. Each key must be listed in PW_ALLOWED_ENV. Dangerous names (NODE_*, NPM_CONFIG_*, PATH, proxies, secrets) are always rejected. Values are never echoed in get_run_status.",
      +  "propertyNames": {
      +    "type": "string"
      +  },
      +  "type": "object"
      +}
  2. Changed1 schema field changedv3.3.0
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  3. First observedv3.2.2

TDQS

C2.9/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full behavioral burden, but it discloses only 'run tests and return results'. It does not mention external-process side effects, snapshot mutation, background execution, the env allowlist/denylist policy, or runtime failure modes. These behaviors exist in the schema but are not surfaced in the description itself.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single front-loaded sentence with zero filler. The purpose is stated first and nothing in the description is wasted; the sentence earns its place even though other dimensions carry the cost of its brevity.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 13-parameter tool with no annotations and no output schema, a one-sentence description is incomplete. The schema compensates for parameter semantics, but the description leaves usage context, behavioral expectations, and return-value meaning ('structured results' is never elaborated) to be inferred.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 92%, so the structured data already documents the parameters thoroughly; the baseline is 3. The description adds no parameter-level meaning beyond the schema, and with coverage that high it does not need to.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb and resource ('Run Playwright tests') and adds a distinguishing trait ('return structured results'), which hints at the synchronous-result contract versus the background/polling siblings. It is clear but does not explicitly differentiate itself from list_tests, get_run_status, or get_failed_tests.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description contains no guidance on when to use this tool versus its siblings. The only usage hint (polling with get_run_status after setting wait=false) lives inside the schema's wait parameter, not the description, so the agent receives no routing or exclusion guidance at the description level.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.