@Test
public void testIsLeaderWhenLeader() {

	given(this.mockLeadershipController.getLocalLeader()).willReturn(Optional.of(this.mockLeader));
	given(this.mockLeader.isCandidate(this.mockCandidate)).willReturn(true);
	boolean result = this.leaderContext.isLeader();
	assertThat(result).isTrue();
}