test(speak): build the MCP test server from fastmcp, the package production imports

This commit is contained in:
jamiepine
2026-10-04 00:00:22 +00:00
committed by capy-ai-staging[bot]
parent 1a3942f3b3
commit 6ad47dda89
+4 -1
View File
@@ -121,7 +121,10 @@ async def test_rest_speak_defaults_to_en_without_profile_language(captured_reque
async def _call_mcp(monkeypatch, profile_language, requested_language=None): async def _call_mcp(monkeypatch, profile_language, requested_language=None):
from mcp.server.fastmcp import FastMCP # Build the server from the same ``fastmcp`` package production imports so
# the registered ``voicebox.speak`` wrapper — where the profile fallback
# lives — is the code under test.
from fastmcp import FastMCP
monkeypatch.setattr( monkeypatch.setattr(
tools, tools,