subhramit commented on code in PR #58225:
URL: https://github.com/apache/spark/pull/58225#discussion_r3891457545


##########
sql/core/src/test/scala/org/apache/spark/sql/errors/QueryExecutionErrorsSuite.scala:
##########
@@ -141,6 +141,21 @@ class QueryExecutionErrorsSuite
     (df1, df2)
   }
 
+  test("SPARK-58945: invalid file extension reports invalidValue") {
+    withTempDir { dir =>
+      val path = new File(dir, "data").getCanonicalPath
+      checkError(
+        exception = intercept[SparkIllegalArgumentException] {
+          spark.range(1).write.option("extension", "12").csv(path)

Review Comment:
   Please see https://github.com/apache/spark/pull/58226 where I already 
covered this. That fix is based on this PR as otherwise only `INTERNAL_ERROR` 
was being surfaced.
   
   For now, I clarified the test scope in 
https://github.com/apache/spark/pull/58225/changes/9a4764181e4216176ab2c260ab6e7074f744c602



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to