diff --git a/jbpm-test-coverage/src/test/java/org/jbpm/test/functional/log/ExecutorLogCleanTest.java b/jbpm-test-coverage/src/test/java/org/jbpm/test/functional/log/ExecutorLogCleanTest.java index b860bb2748..09bf7f2e3c 100644 --- a/jbpm-test-coverage/src/test/java/org/jbpm/test/functional/log/ExecutorLogCleanTest.java +++ b/jbpm-test-coverage/src/test/java/org/jbpm/test/functional/log/ExecutorLogCleanTest.java @@ -112,6 +112,9 @@ public void deleteErrorLogsByDate() throws Exception { List errorList = getExecutorService().getAllErrors(new QueryContext()); Assertions.assertThat(errorList).hasSize(2); + // Abort running process instance + ksession.abortProcessInstance(pi.getId()); + // Delete a record int resultCount = auditService.errorInfoLogDeleteBuilder() .date(errorList.get(0).getTime()) @@ -132,9 +135,6 @@ public void deleteErrorLogsByDate() throws Exception { // Assert remaining records Assertions.assertThat(getExecutorService().getAllErrors(new QueryContext())).hasSize(remaining); - - // Abort running process instance - ksession.abortProcessInstance(pi.getId()); } }