Skip to main content
Glama

electron_generate_test

Generates executable WebdriverIO or Playwright test code from recorded Electron app actions, turning captured UI interactions into runnable tests.

Instructions

Generate executable test code from recorded actions for WebdriverIO or Playwright

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "format": "<format>",
      "testName": "<testName>"
    },
    "name": "electron_generate_test"
  }
}

Input Schema

NameRequiredDescriptionDefault
formatYesTest framework and language format
appPathNo
filenameNo
testNameYestest_electron_app

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

B3/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full behavioral burden. It says the output is 'executable test code' but never states whether a file is written to disk, where it lands, whether existing files are overwritten, or what the call returns. For a generative write-style tool this leaves significant side-effect questions unanswered.

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

Conciseness4/5

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

A single front-loaded sentence with the verb and source stated first and no filler. It is efficient, though the extreme brevity is part of why behavior and parameters go unexplained.

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

Completeness3/5

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

With no output schema and no annotations, the description must explain the result and side effects, and it only partially does. It establishes what is produced and for which frameworks, but omits where code is written, what happens to existing files, and the meaning of three of four parameters.

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

Parameters2/5

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

Schema coverage is only 25%: 'format' documents its own enum, but appPath, filename, and testName are undocumented. The description only restates the framework choice already implied by the enum and adds nothing about how appPath or filename affect output location or naming, so it does not compensate for the coverage gap.

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?

Names a specific verb (generate) and resource (executable test code), plus the input source (recorded actions) and the two supported frameworks. An agent can grasp the core action immediately. It stops short of distinguishing itself from siblings such as electron_generator_write_test or electron_generate_locator, so it doesn't earn a 5.

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

Usage Guidelines3/5

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

The phrase 'from recorded actions' implies a prerequisite (a recording must exist) and hints at ordering in a workflow, but there is no explicit when-to-use statement, no exclusions, and no named alternative among the many sibling generate/write/heal tools. Usage must be inferred rather than read.

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