@Test
public void testGetHosts() throws Exception {

  ClusterDefinition clusterDefinition = new ClusterDefinition(new TestStateProvider(), new TestClusterDefinitionProvider(), new TestHostInfoProvider());
  Set<String> hosts = clusterDefinition.getHosts();
  Assert.assertTrue(hosts.contains("NAMENODE_MASTER.acme.com"));
  Assert.assertTrue(hosts.contains("SECONDARY_NAMENODE_MASTER.acme.com"));
  Assert.assertTrue(hosts.contains("FLUME_SERVICE1.acme.com"));
  Assert.assertTrue(hosts.contains("FLUME_SERVICE2.acme.com"));
  Assert.assertTrue(hosts.contains("FLUME_SERVICE3.acme.com"));
  Assert.assertTrue(hosts.contains("HBASE_MASTER.acme.com"));
  Assert.assertTrue(hosts.contains("HIVE_SERVER_MASTER.acme.com"));
  Assert.assertTrue(hosts.contains("JOBTRACKER_MASTER.acme.com"));
  Assert.assertTrue(hosts.contains("OOZIE_SERVER_MASTER.acme.com"));
  Assert.assertTrue(hosts.contains("slave1.acme.com"));
  Assert.assertTrue(hosts.contains("slave2.acme.com"));
  Assert.assertTrue(hosts.contains("slave3.acme.com"));
  Assert.assertTrue(hosts.contains("WEBHCAT_MASTER.acme.com"));
}