### Question:
SelfCheckingPartyRepository implements PartyRepository { @Override public AcceptResult accept(String owner, String player) { return owner.equalsIgnoreCase(player) ? AcceptResult.ACCEPT_SELF : delegate.accept(owner, player); }  @Override CreateResult create(String owner); @Override Set<String> getPartyMembers(String owner); @Override DisbandResult disband(String owner); @Override InviteResult invite(String owner, String player, int expiration); @Override AcceptResult accept(String owner, String player); @Override RemoveResult remove(String caller, String playerName); @Override Optional<String> getPartyOwner(String playerName);  }### Answer:
@Test public void accept() { SelfCheckingPartyRepository repository = new SelfCheckingPartyRepository(mock(PartyRepository.class)); Assert.assertEquals(AcceptResult.ACCEPT_SELF, repository.accept("owner", "owner")); }