MCP.so
登录

MCP Testing Kit

@thoughtspot

基本信息

分类

开发工具

许可证

MIT

传输方式

stdio

作者

thoughtspot

关于 MCP Testing Kit

The testing library you need to test your MCP servers

MCP Testing Kit 配置

暂无标准配置

该服务器的 README 中没有可解析的 MCP 配置块,请前往代码仓库查看安装说明。

代码仓库

MCP Testing Kit 工具

工具列表暂未提供

当前收录暂时没有可展示的工具列表,不代表服务没有工具。请查阅项目文档了解支持的能力。

工具是从 README 中自动提取的。维护者可以在 ## Tools 标题下列出工具,即可填充这部分内容。

概览

What is mcp-testing-kit?

mcp-testing-kit is a lightweight TypeScript testing library that provides utilities to connect to an MCP server instance, send requests, receive notifications, and assert server behavior. It works with any testing framework (vitest, jest, etc.) and is designed for developers who need to test Model Context Protocol (MCP) servers.

How to use mcp-testing-kit?

Install as a dev dependency using npm i -D mcp-testing-kit. Import the connect and close functions, create an MCP server instance, call connect(server) to get a mock client, use the client methods (e.g., callTool, listTools) to interact with the server, and call close(server) to clean up after each test.

Features of mcp-testing-kit

  • Works with any testing framework (vitest, jest, etc.)
  • Lightweight, provides "just enough" utilities to test an MCP server
  • Full TypeScript support
  • Direct transport layer (no HTTP/SSE dependency)

Use cases of mcp-testing-kit

  • Unit testing MCP server tools, resources, and prompts
  • Verifying server responses to JSON-RPC requests
  • Integration testing without setting up an actual network transport
  • Automating server behavior assertions in CI pipelines

常见问题

1

What testing frameworks does mcp-testing-kit support?

It works with any testing framework, such as vitest, jest, and others.

2

Does it require running an actual MCP server over HTTP/SSE?

No. It creates a dummy transport layer that connects directly to the MCP server instance, bypassing HTTP/SSE.

3

What methods are available on the returned client?

The `connect` function returns a client with methods: `listTools`, `callTool`, `listResources`, `listPrompts`, `getPrompt`, `onNotification`, `onError`, `onProgress`, and `sendToServer`.

4

How do I clean up after a test?

Use the `close(server)` function to close the MCP server instance, typically in an `afterEach` hook.

5

Is mcp-testing-kit written in TypeScript?

Yes, it is built with TypeScript and provides type definitions.

评论

开发工具 分类下的更多 MCP 服务器