diff --git a/hadoop-common-project/hadoop-common/CHANGES.txt b/hadoop-common-project/hadoop-common/CHANGES.txt index db09a93efa9..4d6b88c93d0 100644 --- a/hadoop-common-project/hadoop-common/CHANGES.txt +++ b/hadoop-common-project/hadoop-common/CHANGES.txt @@ -272,7 +272,10 @@ Trunk (Unreleased) HADOOP-8918. test-patch.sh is parsing modified files wrong. (Raja Aluri via suresh) - HADOOP-8589 ViewFs tests fail when tests and home dirs are nested (sanjay Radia) + HADOOP-8589 ViewFs tests fail when tests and home dirs are nested. + (sanjay Radia) + + HADOOP-8974. TestDFVariations fails on Windows. (Chris Nauroth via suresh) OPTIMIZATIONS diff --git a/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/TestDFVariations.java b/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/TestDFVariations.java index b5bd65bc1a9..b291dd2200f 100644 --- a/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/TestDFVariations.java +++ b/hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/fs/TestDFVariations.java @@ -23,6 +23,8 @@ import java.io.File; import java.io.IOException; import java.util.EnumSet; +import org.apache.hadoop.util.Shell; + public class TestDFVariations extends TestCase { public static class XXDF extends DF { @@ -51,7 +53,9 @@ public class TestDFVariations extends TestCase { public void testOSParsing() throws Exception { for (DF.OSType ost : EnumSet.allOf(DF.OSType.class)) { XXDF df = new XXDF(ost.getId()); - assertEquals(ost.getId() + " mount", "/foo/bar", df.getMount()); + assertEquals(ost.getId() + " mount", + Shell.WINDOWS ? df.getDirPath().substring(0, 2) : "/foo/bar", + df.getMount()); } }