Skip to content
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,10 @@
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeAll;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Order;
import org.junit.jupiter.api.MethodOrderer.OrderAnnotation;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.TestMethodOrder;
import org.kie.kogito.event.process.ProcessInstanceVariableDataEvent;
import org.kie.kogito.test.quarkus.QuarkusTestProperty;
import org.kie.kogito.test.quarkus.kafka.KafkaTestClient;
Expand All @@ -48,6 +51,7 @@
import static org.kie.kogito.quarkus.workflows.WorkflowTestUtils.waitForKogitoProcessInstanceEvent;

@QuarkusIntegrationTest
@TestMethodOrder(OrderAnnotation.class)
class PojoServiceIT {

@QuarkusTestProperty(name = KafkaQuarkusTestResource.KOGITO_KAFKA_PROPERTY)
Expand All @@ -73,11 +77,13 @@ public void cleanup() {
}

@Test
@Order(1)
void testPojo() throws Exception {
doIt("pojoService");
}

@Test
@Order(2)
void testFilterPojo() throws Exception {
doIt("pojoServiceFilter");
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,9 @@ public static <T extends DataEvent<?>> JsonPath waitForKogitoProcessInstanceEven

kafkaClient.consume(KOGITO_PROCESSINSTANCES_EVENTS, rawCloudEvent -> {
JsonPath path = new JsonPath(rawCloudEvent);
LOGGER.debug("CLOUD EVENT:\n{}" + path.prettyPrint());
if (LOGGER.isDebugEnabled()) {
LOGGER.debug("CLOUD EVENT: {}", path.prettyPrint());
}
String type = path.get("type");
if (eventType.getSimpleName().equals(type) && predicate.test(path)) {
cloudEvent.set(path);
Expand Down