cloud-fan commented on code in PR #37301:
URL: https://github.com/apache/spark/pull/37301#discussion_r930112075


##########
sql/core/src/test/scala/org/apache/spark/sql/execution/command/v1/ShowFunctionsSuite.scala:
##########
@@ -26,30 +26,22 @@ import org.apache.spark.sql.execution.command
  * table catalogs. The tests that cannot run for all V1 catalogs are located 
in more
  * specific test suites:
  *
- *   - Temporary functions of V1 catalog:
- *     `org.apache.spark.sql.execution.command.v1.ShowTempFunctionsSuite`
- *   - Permanent functions of V1 catalog:
- *     `org.apache.spark.sql.hive.execution.command.ShowFunctionsSuite`
+ *   - V1 In-Memory catalog: 
`org.apache.spark.sql.execution.command.v1.ShowFunctionsSuite`
+ *   - V1 Hive External catalog: 
`org.apache.spark.sql.hive.execution.command.ShowFunctionsSuite`
  */
 trait ShowFunctionsSuiteBase extends command.ShowFunctionsSuiteBase
-  with command.TestsV1AndV2Commands
-
-/**
- * The class contains tests for the `SHOW FUNCTIONS` command to check 
temporary functions.
- */
-class ShowTempFunctionsSuite extends ShowFunctionsSuiteBase with 
CommandSuiteBase {
-  override def commandVersion: String = 
super[ShowFunctionsSuiteBase].commandVersion
-  override protected def isTempFunctions(): Boolean = true
-
+  with command.TestsV1AndV2Commands {
   override protected def createFunction(name: String): Unit = {
-    spark.udf.register(name, (arg1: Int, arg2: String) => arg2 + arg1)
+    sql(s"CREATE FUNCTION $name AS '${classOf[MyDoubleSum].getName}'")

Review Comment:
   V1 in memory catalog supports persistent functions as well: the UDAF 
interface.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to