Skip to content

Commit 6ba5698

Browse files
committed
harden test code
1 parent bba2fa8 commit 6ba5698

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

engine/src/test/java/org/apache/hop/workflow/WorkflowTest.java

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,11 @@
2323
import java.util.concurrent.CountDownLatch;
2424
import org.apache.hop.core.HopEnvironment;
2525
import org.apache.hop.core.exception.HopException;
26+
import org.apache.hop.core.logging.HopLogStore;
2627
import org.apache.hop.workflow.engine.IWorkflowEngine;
2728
import org.apache.hop.workflow.engines.local.LocalWorkflowEngine;
2829
import org.junit.jupiter.api.BeforeAll;
30+
import org.junit.jupiter.api.BeforeEach;
2931
import org.junit.jupiter.api.Test;
3032

3133
class WorkflowTest {
@@ -90,6 +92,13 @@ static void beforeClass() throws HopException {
9092
HopEnvironment.init();
9193
}
9294

95+
@BeforeEach
96+
void before() {
97+
if (!HopLogStore.isInitialized()) {
98+
HopLogStore.init();
99+
}
100+
}
101+
93102
/**
94103
* When a workflow is scheduled twice, it gets the same log channel Id and both logs get merged
95104
*/

0 commit comments

Comments
 (0)