Skip to content

Commit 35ad670

Browse files
authored
fix testParentChildAsyncFork flakiness (#399)
1 parent 9ddfe70 commit 35ad670

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

transact/src/test/java/dev/dbos/transact/workflow/ForkTest.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -448,6 +448,10 @@ public void testParentChildAsyncFork() throws Exception {
448448
assertNull(handle.getStatus().forkedFrom());
449449
assertFalse(handle.getStatus().wasForkedFrom());
450450

451+
// child1 and child2 are fire-and-forget; wait for them before asserting counts
452+
dbos.retrieveWorkflow("child1").getResult();
453+
dbos.retrieveWorkflow("child2").getResult();
454+
451455
assertEquals(1, impl.step1Count);
452456
assertEquals(1, impl.step2Count);
453457
assertEquals(1, impl.child1Count);

0 commit comments

Comments
 (0)