mirror of
https://github.com/BerriAI/litellm.git
synced 2026-11-01 07:03:02 +00:00
test(sdk): terminate the HTTP stream fixture explicitly
Some checks are pending
Some checks are pending
This commit is contained in:
parent
deb0ceee99
commit
5a32061c71
1 changed files with 5 additions and 1 deletions
|
|
@ -69,7 +69,11 @@ def enqueue(body: object, status: int = 200) -> None:
|
|||
|
||||
|
||||
def enqueue_stream() -> None:
|
||||
chunk: Final = {**CHAT, "object": "chat.completion.chunk", "choices": [{"index": 0, "delta": {"content": "pong"}}]}
|
||||
chunk: Final = {
|
||||
**CHAT,
|
||||
"object": "chat.completion.chunk",
|
||||
"choices": [{"index": 0, "delta": {"content": "pong"}, "finish_reason": "stop"}],
|
||||
}
|
||||
RESPONSES.put((200, f"data: {json.dumps(chunk)}\n\ndata: [DONE]\n\n".encode()))
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue