Skip to main content

Crate trip_test

Crate trip_test 

Source
Expand description

Tripwire — Contract testing & regression safety for MCP servers

This library provides the core functionality for testing Model Context Protocol (MCP) server contracts. It allows you to:

  • Connect to MCP servers and enumerate their tools
  • Record baseline snapshots of tool schemas and exchanges
  • Replay snapshots to detect regressions
  • Compare contracts and classify breaking changes

§Architecture

The crate is organized into modules:

  • mcp: MCP protocol client (stdio transport)
  • snapshot: Snapshot file format and I/O
  • diff: Contract diffing and change classification
  • config: Configuration file parsing (TOML)
  • logger: Logging and verbosity control

Re-exports§

pub use mcp::MCPClient;
pub use mcp::Tool;
pub use snapshot::Snapshot;
pub use snapshot::SnapshotMeta;
pub use snapshot::ToolInfo;
pub use snapshot::Exchange;
pub use snapshot::ExchangeResult;
pub use diff::DiffReport;
pub use diff::ToolChange;
pub use diff::ChangeClass;
pub use config::TripwireConfig;

Modules§

config
Configuration file parsing (TOML format).
diff
Contract diffing and change classification.
logger
Logging utilities with verbosity control.
mcp
MCP protocol client implementation.
snapshot
Snapshot file format and I/O.