@Test
public void shouldGetRunState() throws Exception {

  RunState runState = RunState.create(
      INSTANCE, State.QUEUED, StateData.zero(), NOW.minusMillis(1), 17);
  when(storage.readActiveState(INSTANCE)).thenReturn(Optional.of(runState));
  RunState returnedRunState = stateManager.getActiveState(INSTANCE).orElseThrow();
  assertThat(runState, equalTo(returnedRunState));
}