aboutsummaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
authorYe Xianjin <advancedxy@gmail.com>2014-05-13 19:03:51 -0700
committerPatrick Wendell <pwendell@gmail.com>2014-05-13 19:03:51 -0700
commit753b04dea4b04ba9d0dd0011f00e9d70367e76fc (patch)
treefe362d711368a7c24413b188e647ddde38b89e77 /core
parent5c0dafc2c8734a421206a808b73be67b66264dd7 (diff)
downloadspark-753b04dea4b04ba9d0dd0011f00e9d70367e76fc.tar.gz
spark-753b04dea4b04ba9d0dd0011f00e9d70367e76fc.tar.bz2
spark-753b04dea4b04ba9d0dd0011f00e9d70367e76fc.zip
[SPARK-1527] change rootDir*.getName to rootDir*.getAbsolutePath
JIRA issue: [SPARK-1527](https://issues.apache.org/jira/browse/SPARK-1527) getName() only gets the last component of the file path. When deleting test-generated directories, we should pass the generated directory's absolute path to DiskBlockManager. Author: Ye Xianjin <advancedxy@gmail.com> This patch had conflicts when merged, resolved by Committer: Patrick Wendell <pwendell@gmail.com> Closes #436 from advancedxy/SPARK-1527 and squashes the following commits: 4678bab [Ye Xianjin] change rootDir*.getname to rootDir*.getAbsolutePath so the temporary directories are deleted when the test is finished.
Diffstat (limited to 'core')
-rw-r--r--core/src/test/scala/org/apache/spark/storage/DiskBlockManagerSuite.scala2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/src/test/scala/org/apache/spark/storage/DiskBlockManagerSuite.scala b/core/src/test/scala/org/apache/spark/storage/DiskBlockManagerSuite.scala
index 2167718fd2..aaa7714049 100644
--- a/core/src/test/scala/org/apache/spark/storage/DiskBlockManagerSuite.scala
+++ b/core/src/test/scala/org/apache/spark/storage/DiskBlockManagerSuite.scala
@@ -52,7 +52,7 @@ class DiskBlockManagerSuite extends FunSuite with BeforeAndAfterEach with Before
rootDir0.deleteOnExit()
rootDir1 = Files.createTempDir()
rootDir1.deleteOnExit()
- rootDirs = rootDir0.getName + "," + rootDir1.getName
+ rootDirs = rootDir0.getAbsolutePath + "," + rootDir1.getAbsolutePath
println("Created root dirs: " + rootDirs)
}