diff --git a/endpoints/citrus-kafka/src/test/java/org/citrusframework/kafka/integration/KafkaEndpointJavaIT.java b/endpoints/citrus-kafka/src/test/java/org/citrusframework/kafka/integration/KafkaEndpointJavaIT.java
index 2b5abb4b42..6888f12161 100644
--- a/endpoints/citrus-kafka/src/test/java/org/citrusframework/kafka/integration/KafkaEndpointJavaIT.java
+++ b/endpoints/citrus-kafka/src/test/java/org/citrusframework/kafka/integration/KafkaEndpointJavaIT.java
@@ -39,7 +39,7 @@
import static org.citrusframework.kafka.endpoint.selector.KafkaMessageByHeaderSelector.kafkaHeaderContains;
import static org.citrusframework.kafka.endpoint.selector.KafkaMessageByHeaderSelector.kafkaHeaderEquals;
-@Test
+@Test(singleThreaded = true)
public class KafkaEndpointJavaIT extends TestNGCitrusSpringSupport {
@BindToRegistry
@@ -48,7 +48,6 @@ public class KafkaEndpointJavaIT extends TestNGCitrusSpringSupport {
.topic("hello")
.build();
- @Test
@CitrusTest
public void findKafkaEvent_headerEquals_citrus_DSL() {
var body = "findKafkaEvent_headerEquals_citrus_DSL";
@@ -65,7 +64,7 @@ public void findKafkaEvent_headerEquals_citrus_DSL() {
receive(kafkaWithRandomConsumerGroupEndpoint)
.selector(
kafkaMessageFilter()
- .eventLookbackWindow(Duration.ofSeconds(1L))
+ .eventLookbackWindow(Duration.ofSeconds(5L))
.kafkaMessageSelector(kafkaHeaderEquals(key, value))
.build()
)
@@ -74,7 +73,6 @@ public void findKafkaEvent_headerEquals_citrus_DSL() {
);
}
- @Test
@CitrusTest
public void findKafkaEvent_headerContains_citrus_DSL() {
var body = "findKafkaEvent_headerContains_citrus_DSL";
@@ -91,7 +89,7 @@ public void findKafkaEvent_headerContains_citrus_DSL() {
receive(kafkaWithRandomConsumerGroupEndpoint)
.selector(
kafkaMessageFilter()
- .eventLookbackWindow(Duration.ofSeconds(1L))
+ .eventLookbackWindow(Duration.ofSeconds(5L))
.kafkaMessageSelector(kafkaHeaderContains(key, "odo"))
.build()
)
@@ -100,7 +98,6 @@ public void findKafkaEvent_headerContains_citrus_DSL() {
);
}
- @Test
@CitrusTest
public void findKafkaEvent_headerStartsWith_citrus_DSL() {
var body = "findKafkaEvent_headerStartsWith_citrus_DSL";
@@ -117,7 +114,7 @@ public void findKafkaEvent_headerStartsWith_citrus_DSL() {
receive(kafkaWithRandomConsumerGroupEndpoint)
.selector(
kafkaMessageFilter()
- .eventLookbackWindow(Duration.ofSeconds(1L))
+ .eventLookbackWindow(Duration.ofSeconds(5L))
.kafkaMessageSelector(
KafkaMessageByHeaderSelector.builder()
.key(key)
@@ -132,7 +129,6 @@ public void findKafkaEvent_headerStartsWith_citrus_DSL() {
);
}
- @Test
@CitrusTest
public void findKafkaEvent_headerEndsWith_citrus_DSL() {
var body = "findKafkaEvent_headerEndsWith_citrus_DSL";
@@ -149,7 +145,7 @@ public void findKafkaEvent_headerEndsWith_citrus_DSL() {
receive(kafkaWithRandomConsumerGroupEndpoint)
.selector(
kafkaMessageFilter()
- .eventLookbackWindow(Duration.ofSeconds(1L))
+ .eventLookbackWindow(Duration.ofSeconds(5L))
.kafkaMessageSelector(
KafkaMessageByHeaderSelector.builder()
.key(key)
@@ -164,7 +160,6 @@ public void findKafkaEvent_headerEndsWith_citrus_DSL() {
);
}
- @Test
@CitrusTest
public void findKafkaEvent_nothingFound_noMatch_citrus_DSL() {
var body = "findKafkaEvent_nothingFound_noMatch_citrus_DSL";
@@ -181,7 +176,7 @@ public void findKafkaEvent_nothingFound_noMatch_citrus_DSL() {
receive(kafkaWithRandomConsumerGroupEndpoint)
.selector(
kafkaMessageFilter()
- .eventLookbackWindow(Duration.ofSeconds(1L))
+ .eventLookbackWindow(Duration.ofSeconds(5L))
.kafkaMessageSelector(kafkaHeaderEquals(key, "Arwen"))
.build()
)
@@ -195,7 +190,6 @@ public void findKafkaEvent_nothingFound_noMatch_citrus_DSL() {
.hasMessageContaining("Failed to resolve Kafka message using selector");
}
- @Test
@CitrusTest
public void findKafkaEvent_nothingFound_outsideLookbackWindow_citrus_DSL() {
var body = "findKafkaEvent_nothingFound_outsideLookbackWindow_citrus_DSL";
@@ -214,7 +208,7 @@ public void findKafkaEvent_nothingFound_outsideLookbackWindow_citrus_DSL() {
receive(kafkaWithRandomConsumerGroupEndpoint)
.selector(
kafkaMessageFilter()
- .eventLookbackWindow(Duration.ofSeconds(1L))
+ .eventLookbackWindow(Duration.ofSeconds(5L))
.kafkaMessageSelector(kafkaHeaderEquals(key, value))
.build()
)
@@ -228,7 +222,6 @@ public void findKafkaEvent_nothingFound_outsideLookbackWindow_citrus_DSL() {
.hasMessageContaining("Failed to resolve Kafka message using selector");
}
- @Test
@CitrusTest
public void findKafkaEvent_duplicateEntriesFound_citrus_DSL() {
var body = "findKafkaEvent_duplicateEntriesFound_citrus_DSL";
@@ -249,7 +242,7 @@ public void findKafkaEvent_duplicateEntriesFound_citrus_DSL() {
receive(kafkaWithRandomConsumerGroupEndpoint)
.selector(
kafkaMessageFilter()
- .eventLookbackWindow(Duration.ofSeconds(1L))
+ .eventLookbackWindow(Duration.ofSeconds(5L))
.kafkaMessageSelector(kafkaHeaderContains(key, "Gandalf"))
.build()
)
@@ -263,7 +256,6 @@ public void findKafkaEvent_duplicateEntriesFound_citrus_DSL() {
.hasMessageContaining("More than one matching record found in topic");
}
- @Test
@CitrusTest
public void findKafkaEvent_headerEquals_java_DSL() {
var body = "findKafkaEvent_headerEquals_java_DSL";
@@ -277,9 +269,8 @@ public void findKafkaEvent_headerEquals_java_DSL() {
);
then(
- kafkaWithRandomConsumerGroupEndpoint.findKafkaEventHeaderEquals(Duration.ofSeconds(1L), key, value)
+ kafkaWithRandomConsumerGroupEndpoint.findKafkaEventHeaderEquals(Duration.ofSeconds(5L), key, value)
.body(body)
);
}
-
}
diff --git a/endpoints/citrus-kafka/src/test/java/org/citrusframework/kafka/integration/KafkaEndpointXmlIT.java b/endpoints/citrus-kafka/src/test/java/org/citrusframework/kafka/integration/KafkaEndpointXmlIT.java
index 8099e6a3ad..17661b07ce 100644
--- a/endpoints/citrus-kafka/src/test/java/org/citrusframework/kafka/integration/KafkaEndpointXmlIT.java
+++ b/endpoints/citrus-kafka/src/test/java/org/citrusframework/kafka/integration/KafkaEndpointXmlIT.java
@@ -21,7 +21,7 @@
import org.citrusframework.testng.spring.TestNGCitrusSpringSupport;
import org.testng.annotations.Test;
-@Test
+@Test(singleThreaded = true)
public class KafkaEndpointXmlIT extends TestNGCitrusSpringSupport {
@CitrusTestSource(type = TestLoader.SPRING, name = "KafkaEndpointIT_singleMessage")
diff --git a/endpoints/citrus-kafka/src/test/resources/org/citrusframework/kafka/integration/KafkaEndpointIT_selectiveMessage.xml b/endpoints/citrus-kafka/src/test/resources/org/citrusframework/kafka/integration/KafkaEndpointIT_selectiveMessage.xml
index 3e97cd2992..0d546bb1f2 100644
--- a/endpoints/citrus-kafka/src/test/resources/org/citrusframework/kafka/integration/KafkaEndpointIT_selectiveMessage.xml
+++ b/endpoints/citrus-kafka/src/test/resources/org/citrusframework/kafka/integration/KafkaEndpointIT_selectiveMessage.xml
@@ -61,7 +61,7 @@
-
+