@@ -986,6 +986,7 @@ async def test_function_tool_execution_success(
986986 assert isinstance (tool_start_event , RealtimeToolStart )
987987 assert tool_start_event .tool == mock_function_tool
988988 assert tool_start_event .agent == mock_agent
989+ assert tool_start_event .arguments == '{"param": "value"}'
989990
990991 # Check tool end event
991992 tool_end_event = await session ._event_queue .get ()
@@ -1111,6 +1112,7 @@ async def test_function_tool_exception_handling(
11111112 assert session ._event_queue .qsize () == 1
11121113 tool_start_event = await session ._event_queue .get ()
11131114 assert isinstance (tool_start_event , RealtimeToolStart )
1115+ assert tool_start_event .arguments == "{}"
11141116
11151117 # But no tool output should have been sent and no end event queued
11161118 assert len (mock_model .sent_tool_outputs ) == 0
@@ -1133,10 +1135,15 @@ async def test_tool_call_with_complex_arguments(
11331135
11341136 await session ._handle_tool_call (tool_call_event )
11351137
1136- # Verify arguments were passed correctly
1138+ # Verify arguments were passed correctly to tool
11371139 call_args = mock_function_tool .on_invoke_tool .call_args
11381140 assert call_args [0 ][1 ] == complex_args
11391141
1142+ # Verify tool_start event includes arguments
1143+ tool_start_event = await session ._event_queue .get ()
1144+ assert isinstance (tool_start_event , RealtimeToolStart )
1145+ assert tool_start_event .arguments == complex_args
1146+
11401147 @pytest .mark .asyncio
11411148 async def test_tool_call_with_custom_call_id (self , mock_model , mock_agent , mock_function_tool ):
11421149 """Test that tool context receives correct call_id"""
0 commit comments