spark-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From zsxw...@apache.org
Subject spark git commit: [SPARK-18030][TESTS] Adds more checks to collect more info about FileStreamSourceSuite failure
Date Fri, 21 Oct 2016 03:44:37 GMT
Repository: spark
Updated Branches:
  refs/heads/master 2d14ab7e6 -> 1bb99c488


[SPARK-18030][TESTS] Adds more checks to collect more info about FileStreamSourceSuite failure

## What changes were proposed in this pull request?

My hunch is `mkdirs` fails. Just add more checks to collect more info.

## How was this patch tested?

Jenkins

Author: Shixiong Zhu <shixiong@databricks.com>

Closes #15577 from zsxwing/SPARK-18030-debug.


Project: http://git-wip-us.apache.org/repos/asf/spark/repo
Commit: http://git-wip-us.apache.org/repos/asf/spark/commit/1bb99c48
Tree: http://git-wip-us.apache.org/repos/asf/spark/tree/1bb99c48
Diff: http://git-wip-us.apache.org/repos/asf/spark/diff/1bb99c48

Branch: refs/heads/master
Commit: 1bb99c4887e97ae5f55c8c2b392ba5ca72d6168b
Parents: 2d14ab7
Author: Shixiong Zhu <shixiong@databricks.com>
Authored: Thu Oct 20 20:44:32 2016 -0700
Committer: Shixiong Zhu <shixiong@databricks.com>
Committed: Thu Oct 20 20:44:32 2016 -0700

----------------------------------------------------------------------
 .../org/apache/spark/sql/streaming/FileStreamSourceSuite.scala   | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/spark/blob/1bb99c48/sql/core/src/test/scala/org/apache/spark/sql/streaming/FileStreamSourceSuite.scala
----------------------------------------------------------------------
diff --git a/sql/core/src/test/scala/org/apache/spark/sql/streaming/FileStreamSourceSuite.scala
b/sql/core/src/test/scala/org/apache/spark/sql/streaming/FileStreamSourceSuite.scala
index aabdcca..b9e9da9 100644
--- a/sql/core/src/test/scala/org/apache/spark/sql/streaming/FileStreamSourceSuite.scala
+++ b/sql/core/src/test/scala/org/apache/spark/sql/streaming/FileStreamSourceSuite.scala
@@ -664,7 +664,9 @@ class FileStreamSourceSuite extends FileStreamSourceTest {
     def createFile(content: String, src: File, tmp: File): Unit = {
       val tempFile = Utils.tempFileWith(new File(tmp, "text"))
       val finalFile = new File(src, tempFile.getName)
-      src.mkdirs()
+      require(!src.exists(), s"$src exists, dir: ${src.isDirectory}, file: ${src.isFile}")
+      require(src.mkdirs(), s"Cannot create $src")
+      require(src.isDirectory(), s"$src is not a directory")
       require(stringToFile(tempFile, content).renameTo(finalFile))
     }
 


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@spark.apache.org
For additional commands, e-mail: commits-help@spark.apache.org


Mime
View raw message