private List<ShowLocksResponseElement> getLocksWithFilterOptions(HiveTxnManager txnMgr,
      String dbName, String tblName, Map<String, String> partSpec) throws Exception {
    if (dbName == null && tblName != null) {
      dbName = SessionState.get().getCurrentDatabase();
    }
    ShowLocksRequest rqst = new ShowLocksRequest();
    rqst.setDbname(dbName);
    rqst.setTablename(tblName);
    if (partSpec != null) {
      String partName = FileUtils.makePartName(
          new ArrayList<>(partSpec.keySet()), new ArrayList<>(partSpec.values()));
      rqst.setPartname(partName);
    }
    ShowLocksResponse rsp = ((DbLockManager)txnMgr.getLockManager()).getLocks(rqst);
    return rsp.getLocks();
  }
Concurrent delete/delete of same partition - should NOT pass
ql/src/test/org/apache/hadoop/hive/ql/lockmgr/TestDbTxnManager2.java