You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pig.apache.org by ch...@apache.org on 2014/09/07 01:41:07 UTC

svn commit: r1622966 - in /pig/trunk: CHANGES.txt test/org/apache/pig/test/TestAssert.java

Author: cheolsoo
Date: Sat Sep  6 23:41:07 2014
New Revision: 1622966

URL: http://svn.apache.org/r1622966
Log:
PIG-4158: TestAssert is broken in trunk (cheolsoo)

Modified:
    pig/trunk/CHANGES.txt
    pig/trunk/test/org/apache/pig/test/TestAssert.java

Modified: pig/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/pig/trunk/CHANGES.txt?rev=1622966&r1=1622965&r2=1622966&view=diff
==============================================================================
--- pig/trunk/CHANGES.txt (original)
+++ pig/trunk/CHANGES.txt Sat Sep  6 23:41:07 2014
@@ -70,6 +70,8 @@ OPTIMIZATIONS
  
 BUG FIXES
 
+PIG-4158: TestAssert is broken in trunk (cheolsoo)
+
 PIG-4143: Port more mini cluster tests to Tez - part 7 (daijy)
 
 PIG-4149: Rounding issue in FindQuantiles (daijy)

Modified: pig/trunk/test/org/apache/pig/test/TestAssert.java
URL: http://svn.apache.org/viewvc/pig/trunk/test/org/apache/pig/test/TestAssert.java?rev=1622966&r1=1622965&r2=1622966&view=diff
==============================================================================
--- pig/trunk/test/org/apache/pig/test/TestAssert.java (original)
+++ pig/trunk/test/org/apache/pig/test/TestAssert.java Sat Sep  6 23:41:07 2014
@@ -115,11 +115,12 @@ public class TestAssert {
 
       pigServer.registerQuery("A = LOAD 'foo' USING mock.Storage() AS (i:int);");
       pigServer.registerQuery("ASSERT A BY i > 1 , 'i should be greater than 1';");
-      
+
       try {
           pigServer.openIterator("A");
       } catch (FrontendException fe) {
-            Assert.assertTrue(fe.getCause().getCause().getMessage().contains("Assertion violated"));
+          Assert.assertTrue(fe.getCause().getMessage().contains(
+                  "Job terminated with anomalous status FAILED"));
       }
   }
 
@@ -141,8 +142,6 @@ public class TestAssert {
       pigServer.registerQuery("A = LOAD 'foo' USING mock.Storage() AS (i:int);");
       pigServer.registerQuery("ASSERT A BY i > 1 , 'i should be greater than 1';");
 
-      Properties props = pigServer.getPigContext().getProperties();
-      props.setProperty(PigConfiguration.OPT_FETCH, "false");
       try {
           pigServer.openIterator("A");
       } catch (FrontendException fe) {
@@ -150,7 +149,7 @@ public class TestAssert {
                   "Job terminated with anomalous status FAILED"));
       }
   }
-  
+
   /**
    * Verify that alias is not assignable to the ASSERT operator
    * @throws Exception