Repository: hadoop Updated Branches: refs/heads/trunk b2c155f81 -> 5af5f9575
HADOOP-12714. Fix hadoop-mapreduce-client-nativetask unit test which fails because it is not able to open the "glibc bug spill" file. (cmccabe) Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/5af5f957 Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/5af5f957 Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/5af5f957 Branch: refs/heads/trunk Commit: 5af5f9575a906324e5a6ca442217bdaa8ec42fa0 Parents: b2c155f Author: Colin Patrick Mccabe <cmcc...@cloudera.com> Authored: Fri Jan 15 13:53:05 2016 -0800 Committer: Colin Patrick Mccabe <cmcc...@cloudera.com> Committed: Fri Jan 15 13:53:05 2016 -0800 ---------------------------------------------------------------------- hadoop-common-project/hadoop-common/CHANGES.txt | 3 +++ .../hadoop-mapreduce-client-nativetask/pom.xml | 1 + .../apache/hadoop/maven/plugin/cmakebuilder/TestMojo.java | 9 +++++++++ 3 files changed, 13 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/hadoop/blob/5af5f957/hadoop-common-project/hadoop-common/CHANGES.txt ---------------------------------------------------------------------- diff --git a/hadoop-common-project/hadoop-common/CHANGES.txt b/hadoop-common-project/hadoop-common/CHANGES.txt index 132d527..f3e6ff8 100644 --- a/hadoop-common-project/hadoop-common/CHANGES.txt +++ b/hadoop-common-project/hadoop-common/CHANGES.txt @@ -691,6 +691,9 @@ Release 2.9.0 - UNRELEASED HADOOP-12712. Fix some cmake plugin and native build warnings (cmccabe) + HADOOP-12714. Fix hadoop-mapreduce-client-nativetask unit test which fails + because it is not able to open the "glibc bug spill" file. (cmccabe) + Release 2.8.0 - UNRELEASED INCOMPATIBLE CHANGES http://git-wip-us.apache.org/repos/asf/hadoop/blob/5af5f957/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-nativetask/pom.xml ---------------------------------------------------------------------- diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-nativetask/pom.xml b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-nativetask/pom.xml index 45ba85e..1f6324c 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-nativetask/pom.xml +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-nativetask/pom.xml @@ -209,6 +209,7 @@ <goals><goal>cmake-test</goal></goals> <configuration> <testName>test-native-task</testName> + <workingDirectory>${project.build.directory}/native/test</workingDirectory> <source>${basedir}/src</source> <binary>${project.build.directory}/native/test/nttest</binary> <args><arg>--gtest_filter=-Perf.</arg></args> http://git-wip-us.apache.org/repos/asf/hadoop/blob/5af5f957/hadoop-maven-plugins/src/main/java/org/apache/hadoop/maven/plugin/cmakebuilder/TestMojo.java ---------------------------------------------------------------------- diff --git a/hadoop-maven-plugins/src/main/java/org/apache/hadoop/maven/plugin/cmakebuilder/TestMojo.java b/hadoop-maven-plugins/src/main/java/org/apache/hadoop/maven/plugin/cmakebuilder/TestMojo.java index 447331b..e676efd 100644 --- a/hadoop-maven-plugins/src/main/java/org/apache/hadoop/maven/plugin/cmakebuilder/TestMojo.java +++ b/hadoop-maven-plugins/src/main/java/org/apache/hadoop/maven/plugin/cmakebuilder/TestMojo.java @@ -78,6 +78,12 @@ public class TestMojo extends AbstractMojo { private int timeout; /** + * The working directory to use. + */ + @Parameter + private File workingDirectory; + + /** * Path to results directory. */ @Parameter(defaultValue="native-results") @@ -307,6 +313,9 @@ public class TestMojo extends AbstractMojo { getLog().info(bld.toString()); ProcessBuilder pb = new ProcessBuilder(cmd); Exec.addEnvironment(pb, env); + if (workingDirectory != null) { + pb.directory(workingDirectory); + } pb.redirectError(new File(results, testName + ".stderr")); pb.redirectOutput(new File(results, testName + ".stdout")); getLog().info("with extra environment variables " + Exec.envToString(env));