private void addHostToCluster(String hostname,
                                String clusterName) throws AmbariException {
    clusters.addHost(hostname);
    Host h = clusters.getHost(hostname);
    h.setIPv4(hostname + "ipv4");
    h.setIPv6(hostname + "ipv6");

    Map<String, String> hostAttributes = new HashMap<>();
    hostAttributes.put("os_family", "redhat");
    hostAttributes.put("os_release_version", "6.3");
    h.setHostAttributes(hostAttributes);

    clusters.mapHostToCluster(hostname, clusterName);
  }
Tests the kerberosEnabledTest value set in the HDFS metainfo file (stacks/HDP/0.1/services/HDFS/metainfo.xml):
<pre>
{
  "or": [
    {
      "equals": [
        "core-site/hadoop.security.authentication",
        "kerberos"
      ]
    },
    {
      "equals": [
        "hdfs-site/hadoop.security.authentication",
        "kerberos"
      ]
    }
  ]
}
</pre>
ambari-server/src/test/java/org/apache/ambari/server/state/ServiceTest.java