Skip to main content
Glama

test

Debug Go tests in a package using the Delve debugger to identify and resolve issues in test execution.

Instructions

Debug tests in a package

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
packageNoPackage to test (defaults to current directory)
testFlagsNoFlags to pass to go test

Implementation Reference

  • Handler function for the 'test' tool: extracts parameters, calls startDebugSession with test flags, and returns session info.
    case "test": {
      const pkg = (args?.package as string) || ".";
      const testFlags = (args?.testFlags as string[]) || [];
    
      const session = await startDebugSession("test", pkg, ["--", ...testFlags]);
      return {
        content: [{
          type: "text",
          text: `Started test debug session ${session.id} for package ${pkg}`
        }]
      };
  • Schema definition for the 'test' tool, including input parameters for package and testFlags.
    {
      name: "test",
      description: "Debug tests in a package",
      inputSchema: {
        type: "object",
        properties: {
          package: {
            type: "string",
            description: "Package to test (defaults to current directory)"
          },
          testFlags: {
            type: "array",
            items: { type: "string" },
            description: "Flags to pass to go test"
          }
        }
      }
    },
  • src/server.ts:406-407 (registration)
    Registration and dispatch logic for the 'test' tool in the CallToolRequestHandler, routing to handleDebugCommands.
    if (["debug", "attach", "exec", "test", "core", "dap", "replay", "trace"].includes(name)) {
      return handleDebugCommands(name, args);
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 burden of behavioral disclosure. 'Debug tests in a package' implies an interactive or diagnostic operation but doesn't specify whether it's read-only, destructive, requires specific permissions, or has side effects like modifying test state. The description lacks details on execution behavior, error handling, or output format, which are critical for safe and effective use.

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?

The description is a single, efficient sentence with zero wasted words—'Debug tests in a package' is front-loaded and directly conveys the core function. It's appropriately sized for a tool with two well-documented parameters and no complex output schema, making it easy for an agent to parse quickly.

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?

Given the lack of annotations and output schema, the description is incomplete for effective tool use. It doesn't address behavioral aspects like whether debugging is interactive, what output to expect, or how errors are handled. For a debugging tool with potential side effects, more context is needed to ensure the agent can invoke it correctly without unintended consequences.

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%, with clear documentation for both parameters ('package' and 'testFlags'), so the schema does the heavy lifting. The description doesn't add any semantic context beyond what's in the schema—such as explaining typical flag usage or package naming conventions. This meets the baseline for high schema coverage but doesn't enhance parameter understanding.

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 'Debug tests in a package' clearly states the tool's function with a specific verb ('Debug') and resource ('tests in a package'), making the purpose immediately understandable. However, it doesn't distinguish this tool from sibling tools like 'debug' or 'test' (if present in context), which might have overlapping functionality, preventing a perfect score.

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 provides no guidance on when to use this tool versus alternatives. Given sibling tools like 'debug' and 'test' (implied from context), there's no indication of how this tool differs—such as whether it's for Go-specific testing, interactive debugging, or batch execution. This lack of comparative context leaves the agent guessing about appropriate usage scenarios.

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

Install Server

Other Tools

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/dwisiswant0/delve-mcp'

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