bookkeeper-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From si...@apache.org
Subject bookkeeper git commit: BOOKKEEPER-823: Clean up temp files created by hedwig tests (Jia Zhai via sijie)
Date Tue, 07 Jul 2015 06:24:59 GMT
Repository: bookkeeper
Updated Branches:
  refs/heads/master 35fbcc357 -> 8df7e0fb1


BOOKKEEPER-823: Clean up temp files created by hedwig tests (Jia Zhai via sijie)


Project: http://git-wip-us.apache.org/repos/asf/bookkeeper/repo
Commit: http://git-wip-us.apache.org/repos/asf/bookkeeper/commit/8df7e0fb
Tree: http://git-wip-us.apache.org/repos/asf/bookkeeper/tree/8df7e0fb
Diff: http://git-wip-us.apache.org/repos/asf/bookkeeper/diff/8df7e0fb

Branch: refs/heads/master
Commit: 8df7e0fb18547e9805238f4bb15d3d0d67978422
Parents: 35fbcc3
Author: Sijie Guo <sijie@apache.org>
Authored: Mon Jul 6 23:24:26 2015 -0700
Committer: Sijie Guo <sijie@apache.org>
Committed: Mon Jul 6 23:24:26 2015 -0700

----------------------------------------------------------------------
 .../java/org/apache/hedwig/server/TestPubSubServerStartup.java  | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/bookkeeper/blob/8df7e0fb/hedwig-server/src/test/java/org/apache/hedwig/server/TestPubSubServerStartup.java
----------------------------------------------------------------------
diff --git a/hedwig-server/src/test/java/org/apache/hedwig/server/TestPubSubServerStartup.java
b/hedwig-server/src/test/java/org/apache/hedwig/server/TestPubSubServerStartup.java
index 0893a3d..1ad752a 100644
--- a/hedwig-server/src/test/java/org/apache/hedwig/server/TestPubSubServerStartup.java
+++ b/hedwig-server/src/test/java/org/apache/hedwig/server/TestPubSubServerStartup.java
@@ -40,6 +40,7 @@ import org.apache.zookeeper.server.NIOServerCnxnFactory;
 import org.apache.zookeeper.server.ZooKeeperServer;
 import org.apache.zookeeper.test.ClientBase;
 import org.junit.Test;
+import org.apache.hedwig.util.FileUtils;
 
 public class TestPubSubServerStartup {
 
@@ -78,9 +79,7 @@ public class TestPubSubServerStartup {
         writeStringToFile(hedwigParams, hedwigConfigFile);
 
         ClientBase.setupTestEnv();
-        File zkTmpDir = File.createTempFile("zookeeper", "test");
-        zkTmpDir.delete();
-        zkTmpDir.mkdir();
+        File zkTmpDir = FileUtils.createTempDirectory("zookeeper", "test");
 
         ZooKeeperServer zks = new ZooKeeperServer(zkTmpDir, zkTmpDir, zkPort);
 


Mime
View raw message