public static void deleteTable(HBaseTestingUtil testUtil, Admin admin, TableName tableName)
    throws Exception {
    // NOTE: We need a latch because admin is not sync,
    // so the postOp coprocessor method may be called after the admin operation returned.
    MasterSyncObserver observer = testUtil.getHBaseCluster().getMaster().getMasterCoprocessorHost()
      .findCoprocessor(MasterSyncObserver.class);
    observer.tableDeletionLatch = new CountDownLatch(1);
    try {
      admin.disableTable(tableName);
    } catch (TableNotEnabledException e) {
      LOG.debug("Table: " + tableName + " already disabled, so just deleting it.");
    }
    admin.deleteTable(tableName);
    observer.tableDeletionLatch.await();
    observer.tableDeletionLatch = null;
  }
Revoke global permissions from the given user using AccessControlClient. Will wait until all
active AccessController instances have updated their permissions caches or will throw an
exception upon timeout (10 seconds).
hbase-server/src/test/java/org/apache/hadoop/hbase/security/access/SecureTestUtil.java