hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s..@apache.org
Subject hadoop git commit: HDFS-7561. TestFetchImage should write fetched-image-dir under target. Contributed by Liang Xie.
Date Thu, 08 Jan 2015 00:09:23 GMT
Repository: hadoop
Updated Branches:
  refs/heads/branch-2 d3b26454e -> c3c3bb2b0


HDFS-7561. TestFetchImage should write fetched-image-dir under target. Contributed by Liang
Xie.

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

Branch: refs/heads/branch-2
Commit: c3c3bb2b023e8072a9bd1cb4647c6e729aa5196f
Parents: d3b2645
Author: Konstantin V Shvachko <shv@apache.org>
Authored: Wed Jan 7 16:07:16 2015 -0800
Committer: Konstantin V Shvachko <shv@apache.org>
Committed: Wed Jan 7 16:07:16 2015 -0800

----------------------------------------------------------------------
 hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt                 | 3 +++
 .../test/java/org/apache/hadoop/hdfs/TestFetchImage.java    | 9 ++++++++-
 2 files changed, 11 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/c3c3bb2b/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
----------------------------------------------------------------------
diff --git a/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt b/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
index c85c1ab..2eb6714 100644
--- a/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
+++ b/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt
@@ -390,6 +390,9 @@ Release 2.7.0 - UNRELEASED
     HDFS-7564. NFS gateway dynamically reload UID/GID mapping file /etc/nfs.map
     (Yongjun Zhang via brandonli)
 
+    HDFS-7561. TestFetchImage should write fetched-image-dir under target.
+    (Liang Xie via shv)
+
 Release 2.6.1 - UNRELEASED
 
   INCOMPATIBLE CHANGES

http://git-wip-us.apache.org/repos/asf/hadoop/blob/c3c3bb2b/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestFetchImage.java
----------------------------------------------------------------------
diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestFetchImage.java
b/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestFetchImage.java
index a8c6779..0d44357 100644
--- a/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestFetchImage.java
+++ b/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestFetchImage.java
@@ -26,20 +26,27 @@ import java.util.regex.Pattern;
 
 import org.apache.hadoop.conf.Configuration;
 import org.apache.hadoop.fs.FileSystem;
+import org.apache.hadoop.fs.FileUtil;
 import org.apache.hadoop.fs.Path;
 import org.apache.hadoop.hdfs.protocol.HdfsConstants.SafeModeAction;
 import org.apache.hadoop.hdfs.tools.DFSAdmin;
 import org.apache.hadoop.hdfs.util.MD5FileUtils;
 import org.apache.hadoop.io.MD5Hash;
+import org.junit.AfterClass;
 import org.junit.Test;
 
 public class TestFetchImage {
   
   private static final File FETCHED_IMAGE_FILE = new File(
-      System.getProperty("build.test.dir"), "fetched-image-dir");
+      System.getProperty("test.build.dir"), "target/fetched-image-dir");
   // Shamelessly stolen from NNStorage.
   private static final Pattern IMAGE_REGEX = Pattern.compile("fsimage_(\\d+)");
 
+  @AfterClass
+  public static void cleanup() {
+    FileUtil.fullyDelete(FETCHED_IMAGE_FILE);
+  }
+
   /**
    * Download a few fsimages using `hdfs dfsadmin -fetchImage ...' and verify
    * the results.


Mime
View raw message