mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-26 11:14:04 +00:00
chore: rename test
This commit is contained in:
parent
c28e206fc6
commit
c6a2bf76d0
2 changed files with 3 additions and 3 deletions
|
@ -2407,7 +2407,7 @@ async def global_spend_keys(
|
||||||
except ValueError as e:
|
except ValueError as e:
|
||||||
raise HTTPException(
|
raise HTTPException(
|
||||||
status_code=422, detail={"error": f"Invalid limit: {limit}, error: {e}"}
|
status_code=422, detail={"error": f"Invalid limit: {limit}, error: {e}"}
|
||||||
)
|
) from e
|
||||||
|
|
||||||
return response
|
return response
|
||||||
|
|
||||||
|
|
|
@ -734,10 +734,10 @@ def _compare_nested_dicts(
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.asyncio
|
@pytest.mark.asyncio
|
||||||
async def test_global_spend_keys_endpoint(client, monkeypatch):
|
async def test_global_spend_keys_endpoint_limit_validation(client, monkeypatch):
|
||||||
"""
|
"""
|
||||||
Test to ensure that the global_spend_keys endpoint is protected against SQL injection attacks.
|
Test to ensure that the global_spend_keys endpoint is protected against SQL injection attacks.
|
||||||
Verifies that SQL injection attempts are properly parameterized and not directly interpolated.
|
Verifies that the limit parameter is properly parameterized and not directly interpolated.
|
||||||
"""
|
"""
|
||||||
# Create a simple mock for prisma client with empty response
|
# Create a simple mock for prisma client with empty response
|
||||||
mock_prisma_client = MagicMock()
|
mock_prisma_client = MagicMock()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue