mcp-jest
@josharsh
About mcp-jest
Automated testing for Model Context Protocol servers. Ship MCP Servers with confidence.
Basic information
Config
No standard config provided
This server doesn't expose a parseable MCP config block in its README. See the repository for install instructions.
RepositoryTools
No tools detected
We auto-extract tools from the README. The maintainer can list them under a ## Tools heading to populate this section.
Overview
What is mcp-jest?
mcp-jest is a testing framework for Model Context Protocol (MCP) servers – like Jest, but for MCP. It provides automated testing, instant feedback, and CI/CD integration for MCP servers built in any language.
How to use mcp-jest?
Install via npm install mcp-jest (or globally with npm install -g mcp-jest), then either call the mcpTest function from your code or use the mcp-jest CLI command with a server command and list of tools to test. For example: mcp-jest node ./server.js --tools search,email.
Key features of mcp-jest
- Dead simple API – one function call tests your entire server.
- Declarative testing – describe what to test, not how.
- Comprehensive coverage – connection, capability discovery, functional, and validation.
- CI/CD ready – works with GitHub Actions, Jenkins, and more.
- Fast execution – complete suites in under 500ms.
- Zero dependencies beyond the official MCP SDK.
- Flexible usage – library, CLI, config files, TypeScript support.
Use cases of mcp-jest
- Development: test changes instantly during development.
- CI/CD: automated testing in build pipelines.
- Deployment: verify servers work before going live.
- Monitoring: regular health checks in production.
- Documentation: ensure examples actually work.
FAQ from mcp-jest
What runtime does mcp-jest require?
Node.js 18+ (for ESM and modern features) and any MCP server implementing the Model Context Protocol. TypeScript 5+ is optional for full type safety.
Does mcp-jest work with MCP servers in any language?
Yes, as long as the server follows the MCP standard. The README shows examples with Node.js and Python servers.
Can I use mcp-jest in my existing test suite?
Yes, you can import mcp-jest as a library and integrate it with test runners like Jest, Vitest, or Mocha.
How do I test a specific tool's arguments and results?
Pass tool definitions with args and an expect function to mcpTest. The function receives the tool result and should return a boolean or throw.
What is the connection timeout and how can I adjust it?
The default timeout is not specified, but you can increase it using the --timeout CLI flag (e.g., --timeout 60000 for 60 seconds).
More Other MCP servers
🚀 Model Context Protocol (MCP) Curriculum for Beginners
microsoftThis open-source curriculum introduces the fundamentals of Model Context Protocol (MCP) through real-world, cross-language examples in .NET, Java, TypeScript, JavaScript, Rust and Python. Designed for developers, it focuses on practical techniques for building modular, scalable,
MaxKB
1Panel-dev🔥 MaxKB is an open-source platform for building enterprise-grade agents. 强大易用的开源企业级智能体平台。
Inbox Zero AI
elie222The world's best AI personal assistant for email. Open source app to help you reach inbox zero fast.
Blender
ahujasidOpen-source MCP to use Blender with any LLM
MCP Go 🚀
mark3labsA Go implementation of the Model Context Protocol (MCP), enabling seamless integration between LLM applications and external data sources and tools.
Comments