We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent dd39a89 commit 31f0d7eCopy full SHA for 31f0d7e
sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/expressions/ExpressionEvaluationSuite.scala
@@ -830,6 +830,13 @@ class ExpressionEvaluationSuite extends FunSuite {
830
.===(false))
831
}
832
833
+ test("format methods for RichDate and RichTimestamp") {
834
+ val s1:String = RichDate("2014-11-22").format("MMMM d yyyy")
835
+ val s2:String = RichTimestamp("2014-11-22 12:34:56").format("MMMM d HH:mm")
836
+ assert(s1 == "November 22 2014")
837
+ assert(s2 == "November 22 12:34")
838
+ }
839
+
840
test("implicit conversions for RichDate and RichTimestamp") {
841
import org.apache.spark.sql.catalyst.expressions.TimeConversions._
842
val d1 = RichDate("2014-01-01")
0 commit comments