Skip to content

Commit 7833c16

Browse files
author
ochafik
committed
improve error message in weather test
1 parent 53266f9 commit 7833c16

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

examples/server/tests/unit/test_tool_call.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -365,7 +365,7 @@ def do_test_weather(server: ServerProcess, **kwargs):
365365
assert tool_calls and len(tool_calls) == 1, f'Expected 1 tool call in {choice["message"]}'
366366
tool_call = tool_calls[0]
367367
assert choice["message"].get("content") in (None, ""), f'Expected no content in {choice["message"]}'
368-
assert tool_call["function"]["name"] == WEATHER_TOOL["function"]["name"]
368+
assert tool_call["function"]["name"] == WEATHER_TOOL["function"]["name"], f'Expected weather tool call, got {tool_call["function"]["name"]}'
369369
actual_arguments = json.loads(tool_call["function"]["arguments"])
370370
assert 'location' in actual_arguments, f"location not found in {json.dumps(actual_arguments)}"
371371
location = actual_arguments["location"]

0 commit comments

Comments
 (0)