public void postInit() throws Exception {
    miniClusters.postInit(conf);

    sem = new SemanticAnalyzer(new QueryState.Builder().withHiveConf(conf).build());

    testWarehouse = conf.getVar(HiveConf.ConfVars.METASTORE_WAREHOUSE);

    db = Hive.get(conf);
    pd = new ParseDriver();

    initMaterializedViews(); // Create views registry
    firstStartSessionState();

    // setup metastore client cache
    if (conf.getBoolVar(ConfVars.MSC_CACHE_ENABLED)) {
      HiveMetaStoreClientWithLocalCache.init(conf);
    }
  }
Clear out any side effects of running tests
itests/util/src/main/java/org/apache/hadoop/hive/ql/QTestUtil.java