Skip to main content
Glama

get_relevant_tests

Identify which tests are affected by code changes by providing files or a diff, enabling targeted test runs without scanning the full suite.

Instructions

Returns a list of tests likely impacted by the given files or diff.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
cwdNoWorking directory for git diff/app
diffNoUnified diff or name-only list of files
filesNoFiles to analyze
commandNoTest command override (can include {tests})
src_dirNoSource directory to scan for dependenciessrc
base_refNoBase git ref (default: HEAD)HEAD
head_refNoHead git ref (optional)
scan_dirsNoOptional list of directories to scan (relative to project root unless absolute). Overrides src_dir.
project_rootNoProject root directory (defaults to cwd if omitted)
ignore_patternsNoRegex patterns for files to ignore (applied to normalized paths).
include_untrackedNoInclude untracked files from git

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

C2.9/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 burden of behavioral disclosure. It conveys a read-only 'returns a list' outcome, but omits that this likely requires a valid git repository, performs diff and dependency analysis, scans directories, and can be shaped by refs, ignore patterns, and command overrides. The behavior is too underspecified for safe autonomous invocation.

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, grammatically simple sentence that front-loads the action and object. There is no filler, redundancy, or unnecessary elaboration; every word contributes to the core meaning.

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?

With 11 optional parameters, no annotations, no output schema, and several closely related sibling tools, a one-sentence description is not complete enough. The agent is not told what the returned test list looks like, when to provide diff versus files, how refs and scan directories affect results, or what failure modes to expect. The schema mitigates parameter ambiguity but does not fill these gaps.

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?

The input schema covers 100% of parameters, so the baseline is 3. The description adds only a high-level relationship between 'files or diff' and the returned tests, which the schema already documents. No extra parameter semantics, combinations, or precedence information is provided.

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 names a specific verb and resource: it 'Returns a list of tests likely impacted' and identifies the input as files or diff. It is clear on its own, but it does not explicitly distinguish itself from siblings like get_impact_from_diff or run_relevant_tests; the distinction is only implied by the word 'Returns'.

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?

There is no explicit guidance on when to use this tool versus alternatives. The description never mentions run_relevant_tests, get_impact, get_dependencies, or get_impact_from_diff, nor does it state when to prefer this tool over running tests or computing impact. The only usage signal is the implied input of files/diff, which is insufficient in a crowded sibling set.

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