From 05851496337c7bf195a77cba3c1dea54985fdbc1 Mon Sep 17 00:00:00 2001 From: Joshua Valluru <326636767+joshua-berri@users.noreply.github.com> Date: Sun, 27 Sep 2026 07:43:14 -0700 Subject: [PATCH] test(mcp): isolate matrix helper import setup --- tests/unit/integration_support/test_conformance.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/tests/unit/integration_support/test_conformance.py b/tests/unit/integration_support/test_conformance.py index abc8ea8728f..8e20ca6b014 100644 --- a/tests/unit/integration_support/test_conformance.py +++ b/tests/unit/integration_support/test_conformance.py @@ -20,7 +20,8 @@ from pydantic import ValidationError @pytest.mark.asyncio -async def test_negotiation_records_preserve_the_peer_call_contract() -> None: +async def test_negotiation_records_preserve_the_peer_call_contract(monkeypatch: pytest.MonkeyPatch) -> None: + monkeypatch.syspath_prepend(str(Path(__file__).resolve().parents[2])) from integration._support.mcp import math_service from integration.mcp.test_mcp_user_env_vars import UPSTREAM_CALLS from mcp.server.context import ServerRequestContext @@ -52,7 +53,10 @@ async def test_negotiation_records_preserve_the_peer_call_contract() -> None: @pytest.mark.parametrize("file_backed", (False, True)) -def test_peer_drain_preserves_received_requests(tmp_path: Path, file_backed: bool) -> None: +def test_peer_drain_preserves_received_requests( + tmp_path: Path, file_backed: bool, monkeypatch: pytest.MonkeyPatch +) -> None: + monkeypatch.syspath_prepend(str(Path(__file__).resolve().parents[2])) from integration._support.mcp import McpPeer request: Final = {"body": {"method": "tools/call"}, "headers": {"authorization": "synthetic"}}