mcp_tool_test
Generate pytest tests for any MCP tool by specifying the server file path and tool name.
Instructions
Generate pytest tests for an MCP tool.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"server_path": "<server_path>",
"tool_name": "<tool_name>"
},
"name": "mcp_tool_test"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| tool_name | Yes | Name of the tool to test. | |
| output_path | No | Optional path to append the generated tests to. | |
| server_path | Yes | Path to the `mcp_server.py` file. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |