Skip to content

Commit 7f8b1d0

Browse files
committed
test: fix failing tests after conflict resolution
1 parent c10d78a commit 7f8b1d0

File tree

3 files changed

+1
-40
lines changed

3 files changed

+1
-40
lines changed

tests/test_litellm/proxy/_experimental/mcp_server/auth/test_user_api_key_auth_mcp.py

Lines changed: 0 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -171,10 +171,6 @@ async def test_get_allowed_mcp_servers_inheritance_logic(
171171
with patch.object(
172172
MCPRequestHandler, "_get_allowed_mcp_servers_for_team"
173173
) as mock_team_servers:
174-
<<<<<<< HEAD
175-
176-
=======
177-
>>>>>>> 78d744e15d (fix: remove adding Mcp-Protocol-Version header (#14069))
178174
# Configure mocks to return the test data
179175
mock_key_servers.return_value = key_servers
180176
mock_team_servers.return_value = team_servers
@@ -346,17 +342,11 @@ async def test_process_mcp_request_with_server_auth_headers(
346342
# Create an async mock for user_api_key_auth
347343
async def mock_user_api_key_auth(api_key, request):
348344
return UserAPIKeyAuth(
349-
<<<<<<< HEAD
350345
token=(
351346
"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"
352347
if api_key
353348
else None
354349
),
355-
=======
356-
token="e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"
357-
if api_key
358-
else None,
359-
>>>>>>> 78d744e15d (fix: remove adding Mcp-Protocol-Version header (#14069))
360350
api_key=api_key,
361351
user_id="test-user-id" if api_key else None,
362352
team_id="test-team-id" if api_key else None,
@@ -374,10 +364,6 @@ async def mock_user_api_key_auth(api_key, request):
374364
mcp_auth_header,
375365
mcp_servers,
376366
mcp_server_auth_headers,
377-
<<<<<<< HEAD
378-
mcp_protocol_version,
379-
=======
380-
>>>>>>> 78d744e15d (fix: remove adding Mcp-Protocol-Version header (#14069))
381367
) = await MCPRequestHandler.process_mcp_request(scope)
382368

383369
# Assert the results
@@ -557,10 +543,6 @@ async def test_header_extraction(self, headers, expected_result):
557543
mcp_auth_header,
558544
mcp_servers_result,
559545
mcp_server_auth_headers,
560-
<<<<<<< HEAD
561-
mcp_protocol_version,
562-
=======
563-
>>>>>>> 78d744e15d (fix: remove adding Mcp-Protocol-Version header (#14069))
564546
) = await MCPRequestHandler.process_mcp_request(scope)
565547
assert auth_result == mock_auth_result
566548
assert mcp_auth_header == expected_result["mcp_auth"]
@@ -599,10 +581,6 @@ def test_get_mcp_client_side_auth_header_name(
599581
with patch(
600582
"litellm.proxy.proxy_server.general_settings"
601583
) as mock_general_settings:
602-
<<<<<<< HEAD
603-
604-
=======
605-
>>>>>>> 78d744e15d (fix: remove adding Mcp-Protocol-Version header (#14069))
606584
# Configure mocks
607585
mock_get_secret.return_value = env_var
608586
mock_general_settings.get.return_value = general_setting
@@ -706,10 +684,6 @@ async def test_process_mcp_request_with_custom_auth_header(self):
706684
"_get_mcp_client_side_auth_header_name",
707685
return_value="custom-auth-header",
708686
):
709-
<<<<<<< HEAD
710-
711-
=======
712-
>>>>>>> 78d744e15d (fix: remove adding Mcp-Protocol-Version header (#14069))
713687
# Create ASGI scope with custom header
714688
scope = {
715689
"type": "http",
@@ -742,10 +716,6 @@ async def mock_user_api_key_auth(api_key, request):
742716
mcp_auth_header,
743717
mcp_servers,
744718
mcp_server_auth_headers,
745-
<<<<<<< HEAD
746-
mcp_protocol_version,
747-
=======
748-
>>>>>>> 78d744e15d (fix: remove adding Mcp-Protocol-Version header (#14069))
749719
) = await MCPRequestHandler.process_mcp_request(scope)
750720

751721
# Assert the results
@@ -965,10 +935,6 @@ async def mock_user_api_key_auth(api_key, request):
965935
mcp_auth_header,
966936
mcp_servers,
967937
mcp_server_auth_headers,
968-
<<<<<<< HEAD
969-
mcp_protocol_version,
970-
=======
971-
>>>>>>> 78d744e15d (fix: remove adding Mcp-Protocol-Version header (#14069))
972938
) = await MCPRequestHandler.process_mcp_request(scope)
973939

974940
# Assert the results
@@ -997,10 +963,6 @@ async def dummy_handle_request(scope, receive, send):
997963
mcp_auth_header,
998964
mcp_servers,
999965
mcp_server_auth_headers,
1000-
<<<<<<< HEAD
1001-
mcp_protocol_version,
1002-
=======
1003-
>>>>>>> 78d744e15d (fix: remove adding Mcp-Protocol-Version header (#14069))
1004966
) = get_auth_context()
1005967

1006968
# Capture the MCP servers for testing

tests/test_litellm/proxy/_experimental/mcp_server/test_mcp_server_manager.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
MCPServerManager,
1212
_deserialize_env_dict,
1313
)
14-
from litellm.proxy._types import LiteLLM_MCPServerTable, MCPSpecVersion, MCPTransport
14+
from litellm.proxy._types import LiteLLM_MCPServerTable, MCPTransport
1515
from litellm.types.mcp_server.mcp_server_manager import MCPServer
1616

1717

tests/test_litellm/proxy/management_endpoints/test_mcp_management_endpoints.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
from litellm.proxy._types import (
1919
LiteLLM_MCPServerTable,
2020
LitellmUserRoles,
21-
MCPSpecVersion,
2221
MCPTransport,
2322
UserAPIKeyAuth,
2423
)

0 commit comments

Comments
 (0)