You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-commits@hadoop.apache.org by cn...@apache.org on 2013/06/12 20:19:58 UTC

svn commit: r1492322 - in /hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common: ./ src/test/java/org/apache/hadoop/fs/ src/test/java/org/apache/hadoop/fs/viewfs/

Author: cnauroth
Date: Wed Jun 12 18:19:39 2013
New Revision: 1492322

URL: http://svn.apache.org/r1492322
Log:
HADOOP-9638. Merging change r1492314 from branch-2 to branch-2.1-beta.

Modified:
    hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/CHANGES.txt
    hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/FileContextMainOperationsBaseTest.java
    hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/FileContextTestHelper.java
    hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/viewfs/ViewFsBaseTest.java

Modified: hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/CHANGES.txt?rev=1492322&r1=1492321&r2=1492322&view=diff
==============================================================================
--- hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/CHANGES.txt (original)
+++ hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/CHANGES.txt Wed Jun 12 18:19:39 2013
@@ -232,6 +232,9 @@ Release 2.1.0-beta - UNRELEASED
 
     HADOOP-9581. hadoop --config non-existent directory should result in error
     (Ashwin Shankar via jlowe)
+
+    HADOOP-9638. Parallel test changes caused invalid test path for several HDFS
+    tests on Windows (Andrey Klochkov via cnauroth)
     
     HADOOP-9532. HADOOP_CLIENT_OPTS is appended twice by Windows cmd scripts.
     (Chris Nauroth via suresh)

Modified: hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/FileContextMainOperationsBaseTest.java
URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/FileContextMainOperationsBaseTest.java?rev=1492322&r1=1492321&r2=1492322&view=diff
==============================================================================
--- hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/FileContextMainOperationsBaseTest.java (original)
+++ hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/FileContextMainOperationsBaseTest.java Wed Jun 12 18:19:39 2013
@@ -65,7 +65,13 @@ public abstract class FileContextMainOpe
 
   public Path localFsRootPath;
 
-  protected final FileContextTestHelper fileContextTestHelper = new FileContextTestHelper();
+  protected final FileContextTestHelper fileContextTestHelper =
+    createFileContextHelper();
+
+  protected FileContextTestHelper createFileContextHelper() {
+    return new FileContextTestHelper();
+  }
+
   protected static FileContext fc;
   
   final private static PathFilter DEFAULT_FILTER = new PathFilter() {

Modified: hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/FileContextTestHelper.java
URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/FileContextTestHelper.java?rev=1492322&r1=1492321&r2=1492322&view=diff
==============================================================================
--- hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/FileContextTestHelper.java (original)
+++ hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/FileContextTestHelper.java Wed Jun 12 18:19:39 2013
@@ -42,7 +42,15 @@ public final class FileContextTestHelper
    * Create a context with test root relative to the <wd>/build/test/data
    */
   public FileContextTestHelper() {
-      testRootDir = System.getProperty("test.build.data", "target/test/data") + "/" + RandomStringUtils.randomAlphanumeric(10);
+    this(System.getProperty("test.build.data", "target/test/data") + "/" +
+        RandomStringUtils.randomAlphanumeric(10));
+  }
+
+  /**
+   * Create a context with the given test root
+   */
+  public FileContextTestHelper(String testRootDir) {
+    this.testRootDir = testRootDir;
   }
   
   public static int getDefaultBlockSize() {

Modified: hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/viewfs/ViewFsBaseTest.java
URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/viewfs/ViewFsBaseTest.java?rev=1492322&r1=1492321&r2=1492322&view=diff
==============================================================================
--- hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/viewfs/ViewFsBaseTest.java (original)
+++ hadoop/common/branches/branch-2.1-beta/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/viewfs/ViewFsBaseTest.java Wed Jun 12 18:19:39 2013
@@ -75,7 +75,11 @@ public class ViewFsBaseTest {
   Configuration conf;
   FileContext xfcViewWithAuthority; // same as fsView but with authority
   URI schemeWithAuthority;
-  final FileContextTestHelper fileContextTestHelper = new FileContextTestHelper();
+  final FileContextTestHelper fileContextTestHelper = createFileContextHelper();
+
+  protected FileContextTestHelper createFileContextHelper() {
+    return new FileContextTestHelper();
+  }
 
   @Before
   public void setUp() throws Exception {