Skip to main content
Glama

rails_get_test_info

Read-onlyIdempotent

Retrieves Rails test infrastructure and existing test files, including framework, factories, fixtures, CI and coverage setup, so you can locate tests or write new ones for models and controllers.

Instructions

Get test infrastructure and existing test files: framework, factories, fixtures, CI config, coverage setup. Use when: writing new tests, checking what factories/fixtures exist, or finding the test file for a model/controller. Use model:"User" or controller:"Posts" to see existing tests. detail:"full" lists factory and fixture names.

Input Schema

NameRequiredDescriptionDefault
modelNoShow existing tests for a specific model (e.g. 'User'). Looks for model spec/test file.
detailNoDetail level. summary: framework + counts. standard: framework + fixtures + CI (default). full: everything including fixture names, factory names, helper setup.
controllerNoShow existing tests for a specific controller (e.g. 'Posts'). Looks for controller/request spec/test file.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv5.39.1

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare readOnly/idempotent/closed-world, so safety is covered; the description adds what the payload actually contains at each layer. It also clarifies that model:/controller: narrow the output to existing tests rather than filtering results. No statement about behavior when a model has no test file, which is the main remaining gap.

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?

Three tight sentences, front-loaded with the resource and its contents, then when-to-use, then parameter hints. No filler and no repetition.

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?

With no output schema, the description does the work of enumerating returned content and the detail-level tiers, which is sufficient for a read-only introspection tool. It does not address empty/not-found results or how model and controller interact when both are passed.

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 coverage is 100% and the enum is documented in-schema, so the baseline is 3. The description's 'Use model:"User" or controller:"Posts"' and 'detail:"full" lists factory and fixture names' mostly restate the schema descriptions rather than adding new semantics such as precedence when both model and controller are supplied.

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 opens with a specific verb and resource ('Get test infrastructure and existing test files') and enumerates the contents it returns: framework, factories, fixtures, CI config, coverage setup. That lets an agent separate it from mutation siblings like rails_generate_test, though it never names an alternative explicitly.

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 gives an explicit 'Use when:' list covering the three main triggers (writing new tests, checking factories/fixtures, locating a model/controller test file). It stops short of stating when NOT to use it or naming the sibling that should be used instead for generation.

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