@Test
public void shouldReturnRedirectWithLocationIfSetFailsBecauseNotLeaderExceptionIsThrownWithTheLeaderSetToAValidLeader() {

    when(distributedStore.set(KEY, setValue)).thenReturn(Futures.<KeyValue>immediateFailedFuture(new NotLeaderException(self, leader)));
    assertThatValidSetRequestReturnsErrorStatus(ClientResponse.Status.MOVED_PERMANENTLY);
}