diff --git a/tests/integration/responses/test_mcp_authentication.py b/tests/integration/responses/test_mcp_authentication.py index 243ab91d9..5d79dde32 100644 --- a/tests/integration/responses/test_mcp_authentication.py +++ b/tests/integration/responses/test_mcp_authentication.py @@ -4,12 +4,23 @@ # This source code is licensed under the terms described in the LICENSE file in # the root directory of this source tree. +import os + import pytest from tests.common.mcp import make_mcp_server from .helpers import setup_mcp_tools +# Skip these tests in replay mode until recordings are generated +# The authorization parameter creates different request hashes than existing MCP tests +pytestmark = pytest.mark.skipif( + os.environ.get("LLAMA_STACK_TEST_INFERENCE_MODE") == "replay", + reason="No recordings yet for MCP authorization tests. These tests use the authorization parameter " + "which creates different OpenAI request hashes than existing MCP tool tests. " + "Recordings can be generated in CI with record mode, or by running locally with OpenAI API key.", +) + def test_mcp_authorization_bearer(responses_client, text_model_id): """Test that bearer authorization is correctly applied to MCP requests."""