hadoop-mapreduce-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject svn commit: r810135 - in /hadoop/mapreduce/trunk: CHANGES.txt src/test/mapred/org/apache/hadoop/mapred/pipes/TestPipes.java
Date Tue, 01 Sep 2009 17:27:42 GMT
Author: ddas
Date: Tue Sep  1 17:27:41 2009
New Revision: 810135

URL: http://svn.apache.org/viewvc?rev=810135&view=rev
Log:
MAPREDUCE-924. Fixes the TestPipes testcase to use Tool. Contributed by Amareshwari Sriramadasu.

Modified:
    hadoop/mapreduce/trunk/CHANGES.txt
    hadoop/mapreduce/trunk/src/test/mapred/org/apache/hadoop/mapred/pipes/TestPipes.java

Modified: hadoop/mapreduce/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/mapreduce/trunk/CHANGES.txt?rev=810135&r1=810134&r2=810135&view=diff
==============================================================================
--- hadoop/mapreduce/trunk/CHANGES.txt (original)
+++ hadoop/mapreduce/trunk/CHANGES.txt Tue Sep  1 17:27:41 2009
@@ -510,3 +510,6 @@
     MAPREDUCE-687. Fix an assertion in TestMiniMRMapRedDebugScript.
     (Amareshwari Sriramadasu via sharad)
 
+    MAPREDUCE-924. Fixes the TestPipes testcase to use Tool.
+    (Amareshwari Sriramadasu via sharad)
+

Modified: hadoop/mapreduce/trunk/src/test/mapred/org/apache/hadoop/mapred/pipes/TestPipes.java
URL: http://svn.apache.org/viewvc/hadoop/mapreduce/trunk/src/test/mapred/org/apache/hadoop/mapred/pipes/TestPipes.java?rev=810135&r1=810134&r2=810135&view=diff
==============================================================================
--- hadoop/mapreduce/trunk/src/test/mapred/org/apache/hadoop/mapred/pipes/TestPipes.java (original)
+++ hadoop/mapreduce/trunk/src/test/mapred/org/apache/hadoop/mapred/pipes/TestPipes.java Tue
Sep  1 17:27:41 2009
@@ -42,6 +42,7 @@
 import org.apache.hadoop.mapred.TestMiniMRWithDFS;
 import org.apache.hadoop.mapred.Counters.Counter;
 import org.apache.hadoop.util.StringUtils;
+import org.apache.hadoop.util.ToolRunner;
 
 import junit.framework.TestCase;
 
@@ -262,12 +263,14 @@
                        " -program " + 
                        dfs.getFileSystem().makeQualified(wordExec));
     try {
-      Submitter.main(new String[]{"-conf", jobXml.toString(),
+      int ret = ToolRunner.run(new Submitter(),
+                               new String[]{"-conf", jobXml.toString(),
                                   "-input", inDir.toString(),
                                   "-output", nonPipedOutDir.toString(),
                                   "-program", 
                         dfs.getFileSystem().makeQualified(wordExec).toString(),
                                   "-reduces", "2"});
+      assertEquals(0, ret);
     } catch (Exception e) {
       assertTrue("got exception: " + StringUtils.stringifyException(e), false);
     }



Mime
View raw message