Skip to content

Commit

Permalink
x
Browse files Browse the repository at this point in the history
  • Loading branch information
efriis committed Jan 11, 2025
1 parent c5350ea commit 7bca846
Showing 1 changed file with 10 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1192,3 +1192,13 @@ def test_o1(use_max_completion_tokens: bool) -> None:
assert isinstance(response, AIMessage)
assert isinstance(response.content, str)
assert response.content.upper() == response.content


@pytest.mark.scheduled
def test_o1_doesnt_stream() -> None:
"""
When this starts failing, remove the `disable_streaming` validator in
`BaseChatOpenAI`
"""
with pytest.raises(openai.BadRequestError):
list(ChatOpenAI(model="o1", disable_streaming=False).stream("how are you"))

0 comments on commit 7bca846

Please sign in to comment.