Skip to content

Commit 140afd5

Browse files
committed
Check latency is not null in performance tool tests
1 parent c4e942d commit 140afd5

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

src/test/java/com/rabbitmq/stream/perf/StreamPerfTestTest.java

+9-4
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ static void waitOneSecond() throws InterruptedException {
7979
}
8080

8181
ArgumentsBuilder builder() {
82-
return new ArgumentsBuilder().stream(s).rate(100);
82+
return new ArgumentsBuilder().stream(s).rate(1000);
8383
}
8484

8585
@BeforeEach
@@ -348,17 +348,22 @@ void publishConfirmLatencyShouldBeIncludedWhenOptionIsEnabled() throws Exception
348348
waitOneSecond();
349349
run.cancel(true);
350350
waitRunEnds();
351-
assertThat(consoleOutput()).contains("confirm latency");
351+
assertThat(consoleOutput())
352+
.contains("confirm latency")
353+
.doesNotContain("confirm latency 95th 0 ms");
352354
}
353355

354356
@Test
355-
void publishConfirmLatencyShouldNotBeIncludedWhenOptionIsDisabled() throws Exception {
357+
void confirmLatencyShouldBeIncluded() throws Exception {
356358
Future<?> run = run(builder());
357359
waitUntilStreamExists(s);
358360
waitOneSecond();
359361
run.cancel(true);
360362
waitRunEnds();
361-
assertThat(consoleOutput()).doesNotContain("confirm latency");
363+
assertThat(consoleOutput())
364+
.contains("latency 95th")
365+
.doesNotContain("latency 95th 0 ms")
366+
.doesNotContain("confirm latency");
362367
}
363368

364369
private static HttpResponse httpRequest(String urlString) throws Exception {

0 commit comments

Comments
 (0)