@Test(expected = NoSuchObjectException.class)
  public void testListPartitionsSpecByExprEmptyTblName() throws Exception {
    Table t = createTable3PartCols1Part(getClient());

    PartitionsByExprRequest req = new PartitionsByExprRequest(DB_NAME, "",
            ByteBuffer.wrap(new byte[] {'f', 'o', 'o'}));
    req.setMaxParts((short)-1);
    req.setId(t.getId());

    getClient().listPartitionsSpecByExpr(req, new ArrayList<>());
  }
Test class for list partitions related methods on temporary tables.
ql/src/test/org/apache/hadoop/hive/ql/metadata/TestSessionHiveMetastoreClientListPartitionsTempTable.java