StateTransition.createStateTransition(new StubState("step1"), ExitStatus.COMPLETED.getExitCode(), "step3"),
StateTransition.createEndStateTransition(new StubState("step2")), StateTransition
.createEndStateTransition(new StubState("step3"))));
flow.setStateTransitionComparator(new DefaultStateTransitionComparator());
flow.afterPropertiesSet();
FlowExecution execution = flow.start(executor);
assertEquals(FlowExecutionStatus.COMPLETED, execution.getStatus());
assertEquals("step3", execution.getName());
}