@@ -737,11 +737,17 @@ def test_insert_and_get_with_tool_calls_and_results(
737737
738738 # Create tool_calls and tool_results
739739 tool_calls = [
740- ToolCallSummary (id = "call_1" , name = "test_tool" , args = {"param" : "value" }, type = "tool_call" )
740+ ToolCallSummary (
741+ id = "call_1" , name = "test_tool" , args = {"param" : "value" }, type = "tool_call"
742+ )
741743 ]
742744 tool_results = [
743745 ToolResultSummary (
744- id = "call_1" , status = "success" , content = "result data" , type = "tool_result" , round = 1
746+ id = "call_1" ,
747+ status = "success" ,
748+ content = "result data" ,
749+ type = "tool_result" ,
750+ round = 1 ,
745751 )
746752 ]
747753 entry_with_tools = CacheEntry (
@@ -770,13 +776,24 @@ def test_insert_and_get_with_tool_calls_and_results(
770776 # Verify tool_calls JSON
771777 tool_calls_json = sql_params [- 2 ]
772778 assert json .loads (tool_calls_json ) == [
773- {"id" : "call_1" , "name" : "test_tool" , "args" : {"param" : "value" }, "type" : "tool_call" }
779+ {
780+ "id" : "call_1" ,
781+ "name" : "test_tool" ,
782+ "args" : {"param" : "value" },
783+ "type" : "tool_call" ,
784+ }
774785 ]
775786
776787 # Verify tool_results JSON
777788 tool_results_json = sql_params [- 1 ]
778789 assert json .loads (tool_results_json ) == [
779- {"id" : "call_1" , "status" : "success" , "content" : "result data" , "type" : "tool_result" , "round" : 1 }
790+ {
791+ "id" : "call_1" ,
792+ "status" : "success" ,
793+ "content" : "result data" ,
794+ "type" : "tool_result" ,
795+ "round" : 1 ,
796+ }
780797 ]
781798
782799 # Simulate the database returning that data
@@ -788,8 +805,23 @@ def test_insert_and_get_with_tool_calls_and_results(
788805 "start_time" ,
789806 "end_time" ,
790807 None , # referenced_documents
791- [{"id" : "call_1" , "name" : "test_tool" , "args" : {"param" : "value" }, "type" : "tool_call" }],
792- [{"id" : "call_1" , "status" : "success" , "content" : "result data" , "type" : "tool_result" , "round" : 1 }],
808+ [
809+ {
810+ "id" : "call_1" ,
811+ "name" : "test_tool" ,
812+ "args" : {"param" : "value" },
813+ "type" : "tool_call" ,
814+ }
815+ ],
816+ [
817+ {
818+ "id" : "call_1" ,
819+ "status" : "success" ,
820+ "content" : "result data" ,
821+ "type" : "tool_result" ,
822+ "round" : 1 ,
823+ }
824+ ],
793825 )
794826 mock_cursor .fetchall .return_value = [db_return_value ]
795827
0 commit comments