File tree Expand file tree Collapse file tree 1 file changed +12
-6
lines changed
contrib/langchain4j/src/test/java/com/google/adk/models/langchain4j Expand file tree Collapse file tree 1 file changed +12
-6
lines changed Original file line number Diff line number Diff line change @@ -202,24 +202,31 @@ void testGenerateContentWithMultipleFunctionCall() {
202202 when (timeSchema .required ()).thenReturn (Optional .of (List .of ("city" )));
203203
204204 // Create LlmRequest
205- final LlmRequest llmRequest = LlmRequest .builder ()
206- .contents (List .of (Content .fromParts (Part .fromText ("What's the weather in Paris and the current time?" ))))
205+ final LlmRequest llmRequest =
206+ LlmRequest .builder ()
207+ .contents (
208+ List .of (
209+ Content .fromParts (
210+ Part .fromText ("What's the weather in Paris and the current time?" ))))
207211 .build ();
208212
209213 // Mock multiple tool execution requests in the AI response
210- final ToolExecutionRequest weatherRequest = ToolExecutionRequest .builder ()
214+ final ToolExecutionRequest weatherRequest =
215+ ToolExecutionRequest .builder ()
211216 .id ("123" )
212217 .name ("getWeather" )
213218 .arguments ("{\" city\" :\" Paris\" }" )
214219 .build ();
215220
216- final ToolExecutionRequest timeRequest = ToolExecutionRequest .builder ()
221+ final ToolExecutionRequest timeRequest =
222+ ToolExecutionRequest .builder ()
217223 .id ("456" )
218224 .name ("getCurrentTime" )
219225 .arguments ("{\" city\" :\" Paris\" }" )
220226 .build ();
221227
222- final AiMessage aiMessage = AiMessage .builder ()
228+ final AiMessage aiMessage =
229+ AiMessage .builder ()
223230 .text ("" )
224231 .toolExecutionRequests (List .of (weatherRequest , timeRequest ))
225232 .build ();
@@ -257,7 +264,6 @@ void testGenerateContentWithMultipleFunctionCall() {
257264 verify (chatModel ).chat (any (ChatRequest .class ));
258265 }
259266
260-
261267 @ Test
262268 @ DisplayName ("Should handle streaming responses correctly" )
263269 void testGenerateContentWithStreamingChatModel () {
You can’t perform that action at this time.
0 commit comments