@Test
public void nextPossibleTransitions() {

    SurveyInstanceStateMachine completed = SurveyInstanceStateMachineFactory.simple("COMPLETED");
    assertEquals(2, completed.nextPossibleActions(admin, survey).size());
    assertTrue(completed.nextPossibleActions(admin, survey).contains(APPROVING));
    assertTrue(completed.nextPossibleActions(admin, survey).contains(REJECTING));
    assertEquals(0, completed.nextPossibleActions(participant, survey).size());
}