Skip to main content
Glama

Find Test Coverage Gaps

coverage_gaps
Read-onlyIdempotent

Find production methods not called by tests and declared-absent semantic axes, revealing untested code before you claim coverage. Use testReachDepth to distinguish real gaps.

Instructions

List what is NOT covered in a scope: 'uncovered' - production methods no test code calls directly - and 'verifiedAbsent' - semantic axes a developer explicitly declared as 'none'. find_tests_for asks the opposite question for one symbol.

Use it to find untested code before claiming coverage. THE LIST IS ONE HOP, NOT A COVERAGE MEASUREMENT: a method a test reaches THROUGH another method (a CLI verb behind its command builder) is listed although it is exercised - on this server's own solution that is most of the list. So read each entry's testReachDepth: the hops to the nearest directly called method (1 = one of those calls it), ABSENT when no test reaches the method at all. Those are the real gaps. The walk follows interface and abstract dispatch; an entry reached only that way carries viaDispatch.

Returns scope, a 'note' when uncovered is non-empty or no namespace matched, symbolsScanned, uncovered and verifiedAbsent (at most 200 items each), transitivelyReached, judgedUnits, testProjectsExcluded, testFixtureTypesExcluded and reachedOnlyThroughDispatch. uncovered is sorted by type and name, not by depth, so on a large scope the cap cuts alphabetically: narrow the scope to see the rest.

What counts: test code is every method of a test project, every test-attributed method and every method or constructor of a type that declares one. Only ordinary methods are judged. A constructor is a hop: new X(...) reaches the bound overload and its callees. A call from an accessor is not read. Abstract and interface declarations are excluded, and a weak test-name match does not count.

THE POPULATION IS DISCLOSED: judgedUnits is the methods the uncovered list is drawn from, out of symbolsScanned; testProjectsExcluded and testFixtureTypesExcluded count what was set aside as test code. A gap count without its denominator is meaningless. symbolsScanned 0 means the scope matched no namespace.

Read-only. scope is 'solution' or a namespace prefix, case-insensitive, matched on segment boundaries. There is no test switch.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
scopeNo'solution' (default) or a namespace prefix to narrow which symbols are checked.solution
sessionIdYesThe session_id returned by analyze_solution. Also takes an absolute .sln/.slnx/.slnf path, analyzed on first use.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.5.46513
    • changedInput schema / properties / sessionId / description
      Previous value: -"The session_id returned by analyze_solution."New value: +"The session_id returned by analyze_solution. Also takes an absolute .sln/.slnx/.slnf path, analyzed on first use."
  2. First observed

TDQS

A4.8/5.0
Behavior5/5

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

Annotations already cover the safety profile (readOnly, idempotent, non-destructive, closed-world), and the description adds substantial context beyond them: the one-hop limitation, testReachDepth/viaDispatch semantics, the alphabetical 200-item cap, the definition of test code, constructor-as-hop behavior, accessor calls not read, and the judgedUnits denominator. This is exactly the behavioral disclosure an agent needs to interpret results correctly.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Purpose and the critical one-hop caveat are front-loaded, and the sections (returns, what counts, population) are logically ordered. It is long and carries some rhetorical filler ('A gap count without its denominator is meaningless', 'THE LIST IS ONE HOP'), but the density is largely justified by the absent output schema.

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

Completeness5/5

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

With no output schema, the description carries the return-value burden and does so thoroughly, naming every field (scope, note, symbolsScanned, uncovered, verifiedAbsent, transitivelyReached, judgedUnits, testProjectsExcluded, testFixtureTypesExcluded, reachedOnlyThroughDispatch) plus the edge cases for symbolsScanned 0 and the note field.

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 100%, so the baseline is 3, but the description adds real meaning: scope is case-insensitive and matched on segment boundaries, 'solution' is the default, and there is no test toggle. It also notes sessionId accepts an absolute .sln/.slnx/.slnf path analyzed on first use.

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?

States a specific verb and resource ('List what is NOT covered in a scope') and enumerates the two result categories, uncovered and verifiedAbsent. It also explicitly distinguishes itself from find_tests_for ('asks the opposite question for one symbol'), so an agent can route between the two without opening either schema.

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?

Gives an explicit when-to-use ('find untested code before claiming coverage') and names the alternative sibling with the condition that selects it. It also warns about the primary misuse case (treating the one-hop list as a coverage measurement) and tells the agent to narrow scope when the 200-item cap bites.

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