mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-03 02:22:24 +00:00
test(infinity): colocate error regression coverage
This commit is contained in:
parent
4fd17756fd
commit
d3c58cc991
1 changed files with 9 additions and 0 deletions
|
|
@ -5,6 +5,7 @@ from unittest.mock import AsyncMock
|
|||
|
||||
|
||||
import litellm
|
||||
from litellm.llms.infinity.common_utils import InfinityError
|
||||
|
||||
from unittest.mock import patch, MagicMock
|
||||
|
||||
|
|
@ -17,6 +18,14 @@ from litellm.llms.custom_httpx.http_handler import HTTPHandler, AsyncHTTPHandler
|
|||
from litellm.types.utils import EmbeddingResponse, Usage
|
||||
|
||||
|
||||
def test_infinity_error_default_headers_are_not_shared() -> None:
|
||||
first_error = InfinityError(status_code=500, message="first")
|
||||
second_error = InfinityError(status_code=500, message="second")
|
||||
|
||||
assert first_error.headers is None
|
||||
assert second_error.headers is None
|
||||
|
||||
|
||||
@pytest.mark.asyncio()
|
||||
async def test_infinity_rerank():
|
||||
mock_response = AsyncMock()
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue