@Test
public void Should_registerUpCounterShutdownCompletionCallback()
        throws Exception {

    SchedulerActor actor = new SchedulerActor(args);
    ArgumentCaptor<IPoorAction> callbackCaptor = ArgumentCaptor.forClass(IPoorAction.class);
    verify(upCounterMock).onShutdownComplete(callbackCaptor.capture());
    callbackCaptor.getValue().execute();
    verify(service).stop();
    doThrow(ServiceStopException.class).when(service).stop();
    try {
        callbackCaptor.getValue().execute();
        fail();
    } catch (ActionExecuteException ignore) { }
    doThrow(IllegalServiceStateException.class).when(service).stop();
    callbackCaptor.getValue().execute();
}