mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-26 01:12:21 +00:00
test(mcp): patch create_mcp_server_if_identifier_free in the store-model-in-db MCP tests (#42916)
#42791 switched the MCP management endpoints from create_mcp_server to create_mcp_server_if_identifier_free, which keeps the same arguments and returns the created row on success. Two tests in tests/store_model_in_db_tests/test_mcp_servers.py still patched the old name, so mock.patch raised AttributeError before the tests ran and proxy_store_model_in_db_tests has been red on main since.
This commit is contained in:
parent
2cbaa4c9b5
commit
4c68a97c25
1 changed files with 2 additions and 2 deletions
|
|
@ -134,7 +134,7 @@ async def test_create_mcp_server_direct():
|
|||
"litellm.proxy.management_endpoints.mcp_management_endpoints.get_prisma_client_or_throw"
|
||||
) as mock_get_prisma,
|
||||
mock.patch(
|
||||
"litellm.proxy.management_endpoints.mcp_management_endpoints.create_mcp_server",
|
||||
"litellm.proxy.management_endpoints.mcp_management_endpoints.create_mcp_server_if_identifier_free",
|
||||
new_callable=mock.AsyncMock,
|
||||
) as mock_create,
|
||||
mock.patch(
|
||||
|
|
@ -345,7 +345,7 @@ async def test_create_mcp_server_invalid_alias():
|
|||
"litellm.proxy.management_endpoints.mcp_management_endpoints.get_mcp_server"
|
||||
) as mock_get_server,
|
||||
mock.patch(
|
||||
"litellm.proxy.management_endpoints.mcp_management_endpoints.create_mcp_server"
|
||||
"litellm.proxy.management_endpoints.mcp_management_endpoints.create_mcp_server_if_identifier_free"
|
||||
) as mock_create,
|
||||
):
|
||||
from litellm.proxy.management_endpoints.mcp_management_endpoints import (
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue