[SPARK-3752][SQL]: Add tests for different UDF's

Use `checkAnswer` from `QueryTest` to test queries.  It compare answers, gives side by side results when they differ, and prints better exceptions.

```scala
checkAnswer(
  sql("SELECT testUDFIntegerToString(i) FROM integerTable"),
  Seq(Row(1), Row(2)))
```  

Actually, mind fixing the one above too?  I let that slip in somehow.  Thanks :)