module CrystalMcp::Tools::Testing

Overview

Testing tools for the Crystal MCP server.

Extended Modules

Defined in:

tools/testing.cr

Constant Summary

Log = ::Log.for("tools.testing")

Instance Method Summary

Instance Method Detail

def definitions : Array #

Returns the tool definitions for testing tools.


[View source]
def run_spec(path : String, example : String | Nil = nil, fail_fast : Bool = false, timeout_seconds : Int32 = 60) : String #

Runs Crystal specs on a specified file or location.

Returns a JSON string containing execution status, stdout, stderr, and exit code.

Parameters:

  • path: Path to spec file or location (e.g. spec/foo_spec.cr:25).
  • example: Optional example name filter (-e).
  • fail_fast: When true, aborts on first failure (--fail-fast).
  • timeout_seconds: Execution timeout in seconds (default: 60).

[View source]