Skip to content

Commit 62dd703

Browse files
committed
detele unnecessary code
Signed-off-by: zhanghaotong <[email protected]>
1 parent fcc0177 commit 62dd703

File tree

1 file changed

+0
-15
lines changed

1 file changed

+0
-15
lines changed

tests/unittest/others/test_tracing.py

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -168,21 +168,6 @@ def test_tracing(client: openai.OpenAI, model_name: str,
168168
top_p=top_p,
169169
logprobs=False,
170170
)
171-
assert chat_completion.id is not None
172-
assert len(chat_completion.choices) == 1
173-
message = chat_completion.choices[0].message
174-
assert message.content is not None
175-
assert message.role == "assistant"
176-
# test finish_reason
177-
finish_reason = chat_completion.choices[0].finish_reason
178-
completion_tokens = chat_completion.usage.completion_tokens
179-
if finish_reason == "length":
180-
assert completion_tokens == 10
181-
elif finish_reason == "stop":
182-
assert completion_tokens <= 10
183-
else:
184-
raise RuntimeError(
185-
f"finish_reason {finish_reason} not in [length, stop]")
186171

187172
timeout = 10
188173
if not trace_service.evt.wait(timeout):

0 commit comments

Comments
 (0)