@Test
  public void testHadoopAuthKerberosNoLoginAndZookeeperUseKerberos() {
    Assert.assertTrue(HiveConf.getBoolVar(conf, HiveConf.ConfVars.HIVE_ZOOKEEPER_USE_KERBEROS));
    Assert.assertTrue(ZookeeperUtils.isKerberosEnabled(conf));
  }
Secure scenario, invoked e.g. from within Tez AM process.
llap-client/src/test/org/apache/hadoop/hive/registry/impl/TestZookeeperUtils.java