Skip to content

Commit 18cad94

Browse files
author
openingnow
committed
Try to satisfy pyright
1 parent 07a43f8 commit 18cad94

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tools/server/tests/unit/test_compat_oai_responses.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ def test_responses_stream_with_openai_library():
4242

4343
gathered_text = ''
4444
for r in stream:
45-
if type(r) == openai.types.responses.response_text_delta_event.ResponseTextDeltaEvent:
45+
if r.type == "response.output_text.delta":
4646
gathered_text += r.delta
47-
if type(r) == openai.types.responses.response_completed_event.ResponseCompletedEvent:
47+
if r.type == "response.completed":
4848
assert gathered_text == r.response.output_text
4949
assert match_regex("(Suddenly)+", r.response.output_text)

0 commit comments

Comments
 (0)