Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix ut
  • Loading branch information
ulysses-you committed Aug 11, 2020
commit 0f98befac8291feaf86f13ca6912ba0786d0bc23
Original file line number Diff line number Diff line change
Expand Up @@ -447,7 +447,7 @@ class ScalaReflectionSuite extends SparkFunSuite {
}

test("SPARK-32585: Support scala enumeration in ScalaReflection") {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would consider putting a test case in ExpressionEncoderSuite as well as I think that checks various combinations of evaluation.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, not realized this test.

assert(schemaFor[FooClassWithEnum].dataType == StringType)
assert(schemaFor[FooClassWithEnum] == Schema(StringType, false))
assert(serializerFor[FooClassWithEnum].dataType == StructType(Seq(
StructField("i", IntegerType, false),
StructField("e", StringType, false))))
Expand Down