Azure ITs adjustment: prove streaming does chunks the response content
This commit is contained in:
@@ -113,7 +113,9 @@ class AzureOpenAiChatModelFunctionCallIT {
|
||||
.map(AssistantMessage::getContent)
|
||||
.collect(Collectors.joining());
|
||||
logger.info("Response: {}", content);
|
||||
assertThat(counter.get()).isGreaterThan(2);
|
||||
|
||||
assertThat(counter.get()).isGreaterThan(30).as("The response should be chunked in more than 30 messages");
|
||||
|
||||
assertThat(content).containsAnyOf("30.0", "30");
|
||||
assertThat(content).containsAnyOf("10.0", "10");
|
||||
assertThat(content).containsAnyOf("15.0", "15");
|
||||
|
||||
@@ -92,7 +92,7 @@ public class AzureOpenAiAutoConfigurationIT {
|
||||
Flux<ChatResponse> response = chatModel.stream(new Prompt(List.of(userMessage, systemMessage)));
|
||||
|
||||
List<ChatResponse> responses = response.collectList().block();
|
||||
assertThat(responses.size()).isGreaterThan(1);
|
||||
assertThat(responses.size()).isGreaterThan(10);
|
||||
|
||||
String stitchedResponseContent = responses.stream()
|
||||
.map(ChatResponse::getResults)
|
||||
|
||||
Reference in New Issue
Block a user