Skip to content

Commit

Permalink
Fix KafkaMesListenerContTests for proper mocks
Browse files Browse the repository at this point in the history
https://build.spring.io/browse/SK-SK20X-34/

**Cherry-pick to 1.3.x**

# Conflicts:
#	spring-kafka/src/test/java/org/springframework/kafka/listener/KafkaMessageListenerContainerTests.java
  • Loading branch information
artembilan committed Apr 3, 2018
1 parent 4c5399d commit ebbe5f0
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -435,7 +435,7 @@ public void publishEvent(ApplicationEvent event) {
public void testNonResponsiveConsumerEventNotIssuedWithActiveConsumer() throws Exception {
ConsumerFactory<Integer, String> cf = mock(ConsumerFactory.class);
Consumer<Integer, String> consumer = mock(Consumer.class);
given(cf.createConsumer(anyString(), eq(""))).willReturn(consumer);
given(cf.createConsumer(anyString(), anyString())).willReturn(consumer);
ConsumerRecords records = new ConsumerRecords(Collections.emptyMap());
CountDownLatch latch = new CountDownLatch(20);
given(consumer.poll(anyLong())).willAnswer(i -> {
Expand Down

0 comments on commit ebbe5f0

Please sign in to comment.