From a265a7176d347127a012e5bbe0e5038c99f17823 Mon Sep 17 00:00:00 2001 From: Joe G Date: Mon, 15 Jul 2024 12:13:43 -0700 Subject: [PATCH] Don't assume len over 5 when all token ids are 0 --- tests/entrypoints/openai/test_completion.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/entrypoints/openai/test_completion.py b/tests/entrypoints/openai/test_completion.py index 955a7a7a98dcd..f9dbf69c2eaab 100644 --- a/tests/entrypoints/openai/test_completion.py +++ b/tests/entrypoints/openai/test_completion.py @@ -109,7 +109,7 @@ async def test_single_completion(client: openai.AsyncOpenAI, model_name: str, max_tokens=5, temperature=0.0, ) - assert len(completion.choices[0].text) >= 5 + assert len(completion.choices[0].text) >= 1 @pytest.mark.asyncio