Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[SPARK-43767][SQL][TESTS] Fix bug in AvroSuite for 'reading from inva…
…lid path throws exception' ### What changes were proposed in this pull request? The pr aims to fix bug in AvroSuite for 'reading from invalid path throws exception'. ### Why are the changes needed? - As discussed and analyzed in [41271](apache#41271 (comment)) - There is a problem with this UT. Its original intention was to test if there is no file with .avro extensions in the directory, and the read should fail. However, this UT triggered the error as FileUtils.touch instead of spark.read.format("avro").load(dir.toString).The root cause for the failure of this case is that the parent directory was not created. When FileUtils.touch is called in version 1.11.0, it just throws java.io.FileNotFoundException, which covers the error. ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? Pass GA. Closes apache#41289 from panbingkun/SPARK-43767. Authored-by: panbingkun <pbk1982@gmail.com> Signed-off-by: Dongjoon Hyun <dongjoon@apache.org>
- Loading branch information