File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
spring-kafka/src/test/java/org/springframework/kafka/listener Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change 2323import static org .mockito .ArgumentMatchers .isNull ;
2424import static org .mockito .BDDMockito .given ;
2525import static org .mockito .BDDMockito .willAnswer ;
26+ import static org .mockito .Mockito .atLeast ;
2627import static org .mockito .Mockito .inOrder ;
2728import static org .mockito .Mockito .mock ;
2829import static org .mockito .Mockito .spy ;
@@ -1933,7 +1934,7 @@ else if (e instanceof ConsumerStoppedEvent) {
19331934 });
19341935 container .start ();
19351936 assertThat (commitLatch .await (10 , TimeUnit .SECONDS )).isTrue ();
1936- verify (consumer , times (3 )).commitSync (anyMap ());
1937+ verify (consumer , atLeast (3 )).commitSync (anyMap ());
19371938 assertThat (container .isContainerPaused ()).isFalse ();
19381939 container .pause ();
19391940 assertThat (container .isPaused ()).isTrue ();
@@ -1945,7 +1946,7 @@ else if (e instanceof ConsumerStoppedEvent) {
19451946 assertThat (resumeLatch .await (10 , TimeUnit .SECONDS )).isTrue ();
19461947 container .stop ();
19471948 assertThat (stopLatch .await (10 , TimeUnit .SECONDS )).isTrue ();
1948- verify (consumer , times (4 )).commitSync (anyMap ());
1949+ verify (consumer , atLeast (4 )).commitSync (anyMap ());
19491950 }
19501951
19511952 @ SuppressWarnings ({ "unchecked" , "rawtypes" })
You can’t perform that action at this time.
0 commit comments