@Test
  public void testGetRoot() {
    final String response = classRule.getTarget().request(MediaType.APPLICATION_JSON_TYPE)
      .header("X-Jersey-Tracing-Accept", true).get(String.class);
    assertThat(response,
      allOf(containsString("\"hbase_version\":"), containsString("\"cluster_id\":"),
        containsString("\"master_name\":"), containsString("\"backup_master_names\":")));
  }
Tests for the master api_v1 {@link ClusterMetricsResource}.
hbase-server/src/test/java/org/apache/hadoop/hbase/master/http/TestApiV1ClusterMetricsResource.java