Skip to main content
Glama

generate_test_cases

Read-only

Generate a set of test cases (valid, edge, invalid, pairwise) for a given feature description. Declared constraints drive the boundaries: a length or numeric bound ("[8-64]", "min 8 chars", "at least 8 characters" — read from inputs, and from the feature prose when a sentence names exactly one field) yields the last accepted value AND the first rejected one; a format (email/url/uuid, from the type, the field name or the wording) yields malformed-value cases. A bound nobody declared is labelled as this tool's assumption, not as expected behaviour. gherkinFormat renders every case (cap 200, stated in the output) and gherkinScenarioCount lets you check it against totalCases. With your own model (api_key + model, BYOK; the text goes to that provider): ticket → a test suite from a ticket's text (Gherkin, E2E steps, API tests, test data, ambiguities to clarify; a thin ticket gets questions, not invented cases); gherkin + warnings → repairs Gherkin scenarios with syntax errors (missing Given/When/Then…), fixing only the flagged issues.

Example tool call

This call uses example arguments supplied in the tool’s input schema.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "inputs": "email: string\npassword: string, min 8 chars",
      "feature": "Signup form"
    },
    "name": "generate_test_cases"
  }
}

Input Schema

NameRequiredDescriptionDefault
modelNoe.g. "gpt-4o-mini", "claude-haiku-4-5-20251001", "openai/gpt-oss-20b".
inputsNoOptional: list of input parameters (one per line, e.g. "email: string [required]", "password: string [required, min 8 chars]", "age: number [18-99]")
ticketNo{key, summary, description, …}: the ticket's text.
api_keyNoYour provider key, used for this call only.
featureNoFeature or function to test: inputs, expected behaviour, context. A constraint stated here ("password must be at least 8 characters") applies when its sentence names exactly one field.
gherkinNoGherkin to fix.
warningsNoWith gherkin: the warnings to fix.
max_tokensNo
confluence_pagesNoWith ticket: documentation pages.

Output Schema

NameRequiredDescriptionDefault
featureNo
test_casesNo
parsedInputsNo
gherkinFormatNo
gherkinScenarioCountNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.4/5.0
Behavior5/5

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

Beyond the annotations it discloses non-obvious behaviour: BYOK text is sent to the third-party provider, gherkinFormat is capped at 200 cases with the cap stated in output, gherkinScenarioCount is cross-checkable against totalCases, and undeclared bounds are labelled as the tool's own assumptions rather than expected behaviour. These are exactly the traits annotations cannot express.

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?

The primary purpose is front-loaded and no sentence is pure filler, but the body is an unbroken wall of parentheticals and em-dash clauses that is hard to parse on first read. Mode descriptions would earn their place better as separated sentences or bullets rather than a single dense paragraph.

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

Completeness4/5

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

With an output schema present, return values need no explanation, and the description covers mode routing, constraint-derived cases, assumption labelling, and the case cap. Remaining gaps are edge handling such as invalid api_key, feature-only calls with no declared constraints, or precedence when ticket and feature are both supplied.

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

Parameters4/5

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

Schema coverage is already 89%, so the baseline is 3; the description earns above that by explaining semantics the schema cannot: how bounds are parsed ('[8-64]', 'min 8 chars') from inputs and from feature prose only when a sentence names exactly one field, and which parameter combinations trigger which mode. Minor gap: max_tokens and confluence_pages semantics are left entirely to the schema.

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

Purpose5/5

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

Opens with a specific verb+resource and the exact case families produced ('valid, edge, invalid, pairwise'), then enumerates the three modes (feature-only, ticket, gherkin+warnings) with their distinct outputs. An agent can tell which variant of the tool it is invoking without consulting the schema.

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

Usage Guidelines4/5

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

Mode selection is spelled out by input: ticket → test suite from ticket text, gherkin + warnings → repair flagged syntax issues, api_key + model → BYOK routing. It also sets a behavioural guardrail ('a thin ticket gets questions, not invented cases'). It stops short of naming sibling tools or stating when a different tool (e.g. check_api_contract, get_testing_guidelines) is the better choice.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.