dongjoon-hyun commented on a change in pull request #27990:
[SPARK-31229][SQL][TESTS] Add unit tests TypeCoercion.findTypeForComplex and
Cast.canCast in null <> complex types
URL: https://github.com/apache/spark/pull/27990#discussion_r396646582
##########
File path:
sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/analysis/TypeCoercionSuite.scala
##########
@@ -467,18 +467,35 @@ class TypeCoercionSuite extends AnalysisTest {
ArrayType(IntegerType, containsNull = false),
Some(ArrayType(IntegerType, containsNull = true)))
+ widenTest(
+ ArrayType(NullType, containsNull = true),
+ ArrayType(IntegerType, containsNull = false),
+ Some(ArrayType(IntegerType, containsNull = true)))
+
widenTest(
MapType(IntegerType, StringType, valueContainsNull = true),
MapType(IntegerType, StringType, valueContainsNull = false),
Some(MapType(IntegerType, StringType, valueContainsNull = true)))
+ widenTest(MapType(NullType, NullType, true),
Review comment:
nit. new line for `MapType(NullType, NullType, true),`?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]