@Test
  public void testNoKrbConnectionNeg() throws Exception {
    try {
      String url = miniHS2.getBaseJdbcURL() + "default;user=wronguser;pwd=mypwd";
      hs2Conn = DriverManager.getConnection(url);
      fail("noSasl connection should fail");
    } catch (SQLException e) {
      // expected error
      assertEquals("08S01", e.getSQLState().trim());
    }
  }
Negative test, verify that NonKrb connection to secure HS2 fails if it is
user/pwd do not match.
@throws Exception
itests/hive-minikdc/src/test/java/org/apache/hive/minikdc/TestJdbcNonKrbSASLWithMiniKdc.java