@Test
  public void testHplSqlProcedureWithCurrent_DateUdf() throws Throwable {
    String SCRIPT_TEXT =
        "DROP TABLE IF EXISTS result;\n" +
            "CREATE TABLE result (name String, join_date date);\n" +
            "CREATE PROCEDURE p1(s1 string)\n" +
            "BEGIN\n" +
            "INSERT INTO result VALUES(s1, current_date);\n" +
            "END;\n" +
            "p1('Bob');\n" +
            "SELECT * FROM result;" ;
    Date today = new Date(System.currentTimeMillis());
    testScriptFile(SCRIPT_TEXT, args(), "Bob.*" + today.toString());
  }
Start up a local Hive Server 2 for these tests
itests/hive-unit/src/test/java/org/apache/hive/beeline/TestHplSqlViaBeeLine.java