@Test
  public void getFunctionsNoSuchCatalog() throws TException {
    List<String> functionNames = client.getFunctions("nosuch", DEFAULT_DATABASE_NAME, "*");
    Assert.assertEquals(0, functionNames.size());
  }
This test creates and queries a function and then drops it. Good for testing the happy path.
standalone-metastore/metastore-server/src/test/java/org/apache/hadoop/hive/metastore/client/TestFunctions.java