@@ -59,44 +59,4 @@ class SparkScriptTransformationSuite extends BaseScriptTransformationSuite with
5959 assert(e.contains(" TRANSFORM with serde is only supported in hive mode" ))
6060 }
6161 }
62-
63- test(" SPARK-32106: TRANSFORM doesn't support ArrayType/MapType/StructType " +
64- " as output data type (no serde)" ) {
65- assume(TestUtils .testCommandAvailable(" /bin/bash" ))
66- // check for ArrayType
67- val e1 = intercept[SparkException ] {
68- sql(
69- """
70- |SELECT TRANSFORM(a)
71- |USING 'cat' AS (a array<int>)
72- |FROM VALUES (array(1, 1), map('1', 1), struct(1, 'a')) t(a, b, c)
73- """ .stripMargin).collect()
74- }.getMessage
75- assert(e1.contains(" SparkScriptTransformation without serde does not support" +
76- " ArrayType as output data type" ))
77-
78- // check for MapType
79- val e2 = intercept[SparkException ] {
80- sql(
81- """
82- |SELECT TRANSFORM(b)
83- |USING 'cat' AS (b map<int, string>)
84- |FROM VALUES (array(1, 1), map('1', 1), struct(1, 'a')) t(a, b, c)
85- """ .stripMargin).collect()
86- }.getMessage
87- assert(e2.contains(" SparkScriptTransformation without serde does not support" +
88- " MapType as output data type" ))
89-
90- // check for StructType
91- val e3 = intercept[SparkException ] {
92- sql(
93- """
94- |SELECT TRANSFORM(c)
95- |USING 'cat' AS (c struct<col1:int, col2:string>)
96- |FROM VALUES (array(1, 1), map('1', 1), struct(1, 'a')) t(a, b, c)
97- """ .stripMargin).collect()
98- }.getMessage
99- assert(e3.contains(" SparkScriptTransformation without serde does not support" +
100- " StructType as output data type" ))
101- }
10262}
0 commit comments