Skip to main content
Glama
MaaBlock
by MaaBlock

generate_edge_tests

Generate defensive edge-case tests from source code, covering boundary conditions, exception handling, and high branch coverage for Python, TypeScript, and JavaScript.

Instructions

Synthesizes industrial-grade defensive unit tests with 96%+ branch coverage, boundary invariance, and exception handling for any source code.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeYesThe source code snippet or function to test
tierNoTest synthesis tier: 'community' (free) or 'pro' (mutation fuzzing)community
tx_hashNoOptional Polygon or TRON transaction hash verifying 1 USDC/USDT fee for pro tier
languageNoProgramming language (python, typescript, javascript)python
frameworkNoTarget test framework (pytest, jest, vitest)pytest

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observedv1.0.0

TDQS

A3.6/5.0
Behavior2/5

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

With no annotations, the description must carry the behavioral disclosure burden. It discloses some output quality traits (coverage, boundary, exception handling), but it fails to mention the pro-tier payment requirement and tx_hash verification, which is a significant behavioral cost, and it overclaims 'any source code' despite the schema's restricted language/framework enums.

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 sentence that front-loads the verb and resource, then packs relevant quality constraints into a compact list. No wasted sentences or redundant restatements of the tool name.

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 5-parameter tool with no output schema and no annotations, this description is incomplete. It omits what the tool returns, how tier/tx_hash affect behavior, and what language/framework limitations apply, leaving an agent without enough context to invoke it safely and correctly.

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 100%, so the baseline is 3 even without parameter details in the description. The description adds no parameter-level guidance and its 'any source code' claim is arguably inconsistent with the language enum, but the schema itself documents every parameter.

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?

The description names a specific verb ('Synthesizes') and resource ('unit tests') and enriches it with concrete qualities: 96%+ branch coverage, boundary invariance, and exception handling. This clearly separates it from sibling tools like audit_code_defenses and get_paywall_status, which concern auditing and paywall status rather than test generation.

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?

It states the intended use case ('for any source code') and the action (synthesize tests), so an agent can infer when to choose it. It does not explicitly name alternatives or conditions when not to use it, but the sibling tools are sufficiently distinct.

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

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/MaaBlock/autotest-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server