SshKeyAdditionWorkflow extends CancellableWorkflow<SshKeyAdditionWorkflow.SshKeyAdditionPhase> { public SshKeyAdditionPhase INIT() { operationTracker.addLog( "Initializing ssh key addition" ); environment.setStatus( EnvironmentStatus.UNDER_MODIFICATION ); saveEnvironment(); return SshKeyAdditionPhase.ADD_KEY; } SshKeyAdditionWorkflow( final LocalEnvironment environment, final String sshKey,
                                   final TrackerOperation operationTracker,
                                   final EnvironmentManagerImpl environmentManager ); SshKeyAdditionPhase INIT(); SshKeyAdditionPhase ADD_KEY(); void FINALIZE(); @Override void fail( final String message, final Throwable e ); @Override void onCancellation();  }
@Test public void testINIT() throws Exception { workflow.INIT(); verify( environmentManager ).update( environment ); }