@Test
  public void testQueryCacheIgnored() throws Exception {

    reset(mockedAuthorizer);
    int status = driver.compile("select i from " + acidTableName
        + " where i > 0 ", true);
    assertEquals(0, status);
    List<HivePrivilegeObject> outputs = getHivePrivilegeObjectInputs().getRight();
    List<HivePrivilegeObject> inputs = getHivePrivilegeObjectInputs().getLeft();
    assertEquals("No outputs for a select", 0, outputs.size());
    assertEquals("One input for this select", 1, inputs.size());
  }
This factory creates a mocked HiveAuthorizer class. Use the mocked class to
capture the argument passed to it in the test case.
itests/hive-unit/src/test/java/org/apache/hadoop/hive/ql/security/authorization/plugin/TestHiveAuthorizerCheckInvocation.java