Skip to main content
Glama

Run Tests

run_tests

Run the project's test suite in a sandbox and parse the results to show pass/fail counts and failing test names. Auto-detects the runner or uses a custom command to verify the project still works.

Instructions

Run the project's test suite inside a sandbox and parse the results.

USE THIS instead of execute_experiment when you want to know whether the project still works -- it detects the runner (npm, pytest, cargo, go, make) by looking at what is actually in the sandbox, and parses counts out of the output.

RETURNS exit code, stdout/stderr, duration and, when parseable, a summary with passed/failed/total and the names of failing tests. If test_summary.detected is false, trust the exit code, not the zeros.

Pass command to override detection.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
commandNoExplicit test command. Omit to auto-detect.
timeoutNoSeconds before the run is killed.
experiment_idYesThe experiment to test in.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
errorNo
job_idYes
statusYes
stderrNo
stdoutNo
commandYes
exit_codeNo
frameworkNo
duration_msNo
test_summaryNo
experiment_idYes
stderr_truncatedNo
stdout_truncatedNo

Schema Changelog

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

  1. First observedv0.1.0

TDQS

A4.6/5.0
Behavior4/5

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

With no annotations, the description carries the burden of explaining behavior, and it does so well: auto-detects the runner, parses results, returns exit code/stdout/stderr/duration, and warns to trust exit code over zeros when test_summary.detected is false. It does not explicitly address side effects, but the sandbox context implies isolation.

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 well-structured into purpose, usage guidance, and return behavior, with no filler. Every sentence adds useful information, and the line breaks improve readability.

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?

Given the tool's moderate complexity—auto-detection, command override, parsed test summaries—the description is complete enough for an agent to call it correctly. It does not detail output schema fields, but it sufficiently describes what is returned, so no critical context appears missing.

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?

The schema already covers all three parameters with clear descriptions, and the tool description adds the important note that command overrides detection. experiment_id, timeout, and command are all semantically meaningful with no ambiguity.

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 clearly states the tool runs the project's test suite inside a sandbox and parses results. It also explicitly contrasts with execute_experiment by framing this as the way to determine whether the project still works, which distinguishes it from siblings.

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

Usage Guidelines5/5

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

It gives explicit guidance to use this instead of execute_experiment when the goal is checking whether the project still works. It also explains that command can override auto-detection, giving concrete usage direction.

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/Dhananjay-JSR/sandbox-mcp'

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