Skip to main content
Glama

Test Scaffold Phpunit

test_scaffold_phpunit

Create PHPUnit test classes for Drupal modules with configurable test type, class name, and methods to reduce manual test setup.

Instructions

Scaffold a PHPUnit test class.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
moduleYes
test_typeNounit
class_nameNo
test_methodsNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

C2.6/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full behavioral burden, and it discloses almost nothing. It does not say that files are written to disk, where they are placed, whether existing files are overwritten, or whether the generated class is immediately runnable. For a scaffolding/mutation tool this is a substantial gap.

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

Conciseness3/5

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

A single front-loaded sentence with no filler, which is structurally sound. The brevity here reflects under-specification rather than disciplined conciseness, so it lands at minimum-viable rather than strong.

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?

An output schema exists, so return-value documentation is not required, and the required 'module' param is at least structurally enforced. But with zero annotation coverage, zero parameter documentation, and no statement of side effects for a tool that writes test files, the description is not complete enough to invoke confidently.

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 description coverage is 0% and the description documents none of the four parameters. 'test class' loosely hints at class_name, but module, test_type (with its default 'unit') and test_methods are left entirely unexplained, so the agent gets no syntax or semantic help.

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?

States a specific verb ('Scaffold') and a specific resource ('PHPUnit test class'), so an agent can tell it apart from test_run_phpunit (executes tests) at a glance. It does not, however, explicitly distinguish itself from the close siblings test_scaffold_behat or test_scaffold_nightwatch.

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 when-to-use guidance, no prerequisites, and never names an alternative. An agent must infer that this is the scaffolding counterpart to test_run_phpunit purely from the name.

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

Deploy Server

Other Tools