@Test
public void updateWorkflowInstanceCreatesActionWhenNewWorkflowIsCreated() {

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