@Test
public void testAtlas() throws Exception {

  final String expectedHostGroupName = "host_group_1";
  final String host1 = "c6401.ambari.apache.org";
  final String host2 = "c6402.ambari.apache.org";
  final String host3 = "c6403.ambari.apache.org";
  Map<String, Map<String, String>> properties = new HashMap<String, Map<String, String>>();
  Map<String, String> atlasProperties = new HashMap<String, String>();
  properties.put("application-properties", atlasProperties);
  // setup properties that include host information
  atlasProperties.put("atlas.kafka.bootstrap.servers", "localhost:6667");
  atlasProperties.put("atlas.kafka.zookeeper.connect", "localhost:2181");
  atlasProperties.put("atlas.graph.index.search.solr.zookeeper-url", "localhost:2181/ambari-solr");
  atlasProperties.put("atlas.graph.storage.hostname", "localhost");
  atlasProperties.put("atlas.audit.hbase.zookeeper.quorum", "localhost");
  Configuration clusterConfig = new Configuration(properties, Collections.<String, Map<String, Map<String, String>>>emptyMap());
  Collection<String> hgComponents = new HashSet<String>();
  hgComponents.add("KAFKA_BROKER");
  hgComponents.add("ZOOKEEPER_SERVER");
  hgComponents.add("HBASE_MASTER");
  List<String> hosts = new ArrayList<String>();
  hosts.add(host1);
  hosts.add(host2);
  hosts.add(host3);
  TestHostGroup group1 = new TestHostGroup(expectedHostGroupName, hgComponents, hosts);
  Collection<TestHostGroup> hostGroups = new HashSet<TestHostGroup>();
  hostGroups.add(group1);
  ClusterTopology topology = createClusterTopology(bp, clusterConfig, hostGroups);
  BlueprintConfigurationProcessor updater = new BlueprintConfigurationProcessor(topology);
  // call top-level cluster config update method
  updater.doUpdateForClusterCreate();
  List<String> hostArray =
      Arrays.asList(atlasProperties.get("atlas.kafka.bootstrap.servers").split(","));
  List<String> expected =
      Arrays.asList("c6401.ambari.apache.org:6667","c6402.ambari.apache.org:6667", "c6403.ambari.apache.org:6667");
  Assert.assertTrue(hostArray.containsAll(expected) && expected.containsAll(hostArray));
  hostArray = Arrays.asList(atlasProperties.get("atlas.kafka.zookeeper.connect").split(","));
  expected =
      Arrays.asList("c6401.ambari.apache.org:2181","c6402.ambari.apache.org:2181", "c6403.ambari.apache.org:2181");
  Assert.assertTrue(hostArray.containsAll(expected) && expected.containsAll(hostArray));
  hostArray = Arrays.asList(atlasProperties.get("atlas.graph.index.search.solr.zookeeper-url").split(","));
  expected =
      Arrays.asList("c6401.ambari.apache.org:2181/ambari-solr","c6402.ambari.apache.org:2181/ambari-solr", "c6403.ambari.apache.org:2181/ambari-solr");
  Assert.assertTrue(hostArray.containsAll(expected) && expected.containsAll(hostArray));
  hostArray = Arrays.asList(atlasProperties.get("atlas.graph.storage.hostname").split(","));
  expected =
      Arrays.asList("c6401.ambari.apache.org","c6402.ambari.apache.org", "c6403.ambari.apache.org");
  Assert.assertTrue(hostArray.containsAll(expected) && expected.containsAll(hostArray));
  hostArray = Arrays.asList(atlasProperties.get("atlas.audit.hbase.zookeeper.quorum").split(","));
  expected =
      Arrays.asList("c6401.ambari.apache.org","c6402.ambari.apache.org", "c6403.ambari.apache.org");
  Assert.assertTrue(hostArray.containsAll(expected) && expected.containsAll(hostArray));
}