@Test
public void shouldReturnInternalServerErrorIfSetFailsBecauseAnExceptionIsThrownInServiceCode() {

    when(distributedStore.set(KEY, setValue)).thenThrow(new IllegalStateException("service code terminated unexpectedly"));
    assertThatValidSetRequestReturnsErrorStatus(ClientResponse.Status.INTERNAL_SERVER_ERROR);
}