### Question:
PurgeBannedPlayersCommand implements ExecutableCommand { @Override public void executeCommand(CommandSender sender, List<String> arguments) { Set<OfflinePlayer> bannedPlayers = bukkitService.getBannedPlayers(); Set<String> namedBanned = new HashSet<>(bannedPlayers.size()); for (OfflinePlayer offlinePlayer : bannedPlayers) { namedBanned.add(offlinePlayer.getName().toLowerCase()); } purgeService.purgePlayers(sender, namedBanned, bannedPlayers.toArray(new OfflinePlayer[bannedPlayers.size()])); }  @Override void executeCommand(CommandSender sender, List<String> arguments);  }### Answer:
@Test public void shouldForwardRequestToService() { String[] names = {"bannedPlayer", "other_banned", "evilplayer", "Someone"}; OfflinePlayer[] players = offlinePlayersWithNames(names); given(bukkitService.getBannedPlayers()).willReturn(newHashSet(players)); CommandSender sender = mock(CommandSender.class); command.executeCommand(sender, Collections.emptyList()); verify(bukkitService).getBannedPlayers(); verify(purgeService).purgePlayers(eq(sender), eq(asLowerCaseSet(names)), argThat(arrayContainingInAnyOrder(players))); }