Skip to content

Commit f7931c5

Browse files
authored
integ tests - fix flaky structured output test (#1030)
1 parent 6cf4f7e commit f7931c5

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

tests_integ/models/providers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ def __init__(self):
131131
id="gemini",
132132
environment_variable="GOOGLE_API_KEY",
133133
factory=lambda: GeminiModel(
134-
api_key=os.getenv("GOOGLE_API_KEY"),
134+
client_args={"api_key": os.getenv("GOOGLE_API_KEY")},
135135
model_id="gemini-2.5-flash",
136136
params={"temperature": 0.7},
137137
),

tests_integ/models/test_conformance.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,4 @@ class Weather(BaseModel):
5757
agent = Agent(model)
5858

5959
result = agent.structured_output(Weather, "How are you?")
60-
61-
assert len(result.time) > 0
62-
assert len(result.weather) > 0
60+
assert isinstance(result, Weather)

0 commit comments

Comments
 (0)