Assert.assertNotNull(configGroup);
ConfigGroupEntity configGroupEntity = configGroupDAO.findByName("cg-test");
Assert.assertNotNull(configGroupEntity);
Assert.assertEquals("HDFS", configGroupEntity.getTag());
ConfigGroupConfigMappingEntity configMappingEntity = configGroupEntity
.getConfigGroupConfigMappingEntities().iterator().next();
Assert.assertNotNull(configMappingEntity);
Assert.assertEquals("hdfs-site", configMappingEntity.getConfigType());
Assert.assertEquals("testversion", configMappingEntity.getVersionTag());
Assert.assertNotNull(configMappingEntity.getClusterConfigEntity());
Assert.assertTrue(configMappingEntity
.getClusterConfigEntity().getData().contains("a"));
ConfigGroupHostMappingEntity hostMappingEntity = configGroupEntity
.getConfigGroupHostMappingEntities().iterator().next();
Assert.assertNotNull(hostMappingEntity);
Assert.assertEquals("h1", hostMappingEntity.getHostname());