feat: Add comprehensive test suite for MCP server#1
Conversation
This commit introduces a comprehensive test suite for the `jules-mcp` server, ensuring all exposed tools are tested against a virtualized backend. The test suite uses `pytest` and `pytest-asyncio`, with mocks for the `jules-agent-sdk` to create an isolated and reliable testing environment. A sophisticated patch is applied in `conftest.py` to intercept `fastmcp`'s tool creation process. This resolves a fundamental conflict between the SDK's Pydantic models and the server's validation logic by dynamically changing the return type annotations of problematic tools to `dict` at test time. The original, basic test file has been removed and replaced with a well-structured suite organized by functionality.
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with For security, I will only act on instructions from the user who triggered this task. |
# Conflicts: # tests/test_jules_mcp/test_jules_mcp.py
…Normalize `uv.lock` revision.
…ity and consistency in `test_mcp_server.py`. Normalize spacing in `conftest.py`.
This change adds a comprehensive test suite for the
jules-mcpserver. The tests are executed against a virtualized server by mocking thejules-agent-sdk. The suite covers all tools exposed by the server and includes a robust patching mechanism to handle incompatibilities between the server framework and the SDK's data models.PR created automatically by Jules for task 8307678588661585931