@Test
public void updateWorkflowInstanceCreatesActionWhenChildWorkflowIsCreated() {

  WorkflowInstance instance = updateInstanceBuilder().build();
  WorkflowInstanceAction action = constructActionBuilder(instance.id).build();
  WorkflowInstance childWorkflow = constructWorkflowInstanceBuilder().build();
  dao.updateWorkflowInstanceAfterExecution(instance, action, asList(childWorkflow), emptyWorkflows, false);
  assertThat(updatedInstance().actions.size(), is(1));
}