### Question:
Burrow { public List<ClusterClient> getClusters() throws IOException { return ((List<String>)this.request().get("clusters")).stream() .map(ClusterClient::new) .collect(Collectors.toList()); } Burrow(Map<String, Object> conf);  Burrow(Map<String, Object> conf, OkHttpClient client);   Burrow(Map<String, Object> conf, OkHttpClient client, boolean doHealthCheck); List<String> consumerGroups(String cluster); Map<String, Object> getConsumerGroupStatus(String cluster, String consumerGroup); List<ClusterClient> getClusters();  }### Answer:
@Test public void testClusters() throws Exception { OkHttpClient client = Mockito.mock(OkHttpClient.class); Map<String, Object> response = new HashMap<>(); List<String> expected = Lists.newArrayList("c1", "c2"); response.put("clusters", expected); when(client.newCall(any())).then(respondWithJson(response)); Burrow burrow = new Burrow(CONF, client); List<Burrow.ClusterClient> clients = burrow.getClusters(); assertEquals(2, clients.size()); assertEquals(expected, clients.stream().map(Burrow.ClusterClient::getCluster).collect(Collectors.toList())); verify(client).newCall(expectPath("/v3/kafka")); }