You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@oozie.apache.org by an...@apache.org on 2012/01/06 22:58:19 UTC

svn commit: r1228449 - in /incubator/oozie/branches/3.1: core/src/test/java/org/apache/oozie/service/TestStatusTransitService.java release-log.txt

Author: angeloh
Date: Fri Jan  6 21:58:19 2012
New Revision: 1228449

URL: http://svn.apache.org/viewvc?rev=1228449&view=rev
Log:
Fix unit test failure in TestStatusTransitService.java. (Prakha via Mohammad)

Modified:
    incubator/oozie/branches/3.1/core/src/test/java/org/apache/oozie/service/TestStatusTransitService.java
    incubator/oozie/branches/3.1/release-log.txt

Modified: incubator/oozie/branches/3.1/core/src/test/java/org/apache/oozie/service/TestStatusTransitService.java
URL: http://svn.apache.org/viewvc/incubator/oozie/branches/3.1/core/src/test/java/org/apache/oozie/service/TestStatusTransitService.java?rev=1228449&r1=1228448&r2=1228449&view=diff
==============================================================================
--- incubator/oozie/branches/3.1/core/src/test/java/org/apache/oozie/service/TestStatusTransitService.java (original)
+++ incubator/oozie/branches/3.1/core/src/test/java/org/apache/oozie/service/TestStatusTransitService.java Fri Jan  6 21:58:19 2012
@@ -198,13 +198,16 @@ public class TestStatusTransitService ex
         assertEquals(CoordinatorJob.Status.KILLED, coordJob.getStatus());
         assertEquals(CoordinatorAction.Status.KILLED, coordAction.getStatus());
         assertEquals(WorkflowJob.Status.KILLED, wfJob.getStatus());
-        assertEquals(true, coordJob.isPending());
         assertEquals(false, coordAction.isPending());
 
         Runnable runnable = new StatusTransitRunnable();
         runnable.run();
 
-        waitFor(5 * 1000, new Predicate() {
+        // Status of coordJobBean is being updated asynchronously.
+        // Increasing wait time to atmost 10s to make sure there is
+        // sufficient time for the status to get updated. Thus, resulting
+        // in following assertion not failing.
+        waitFor(10 * 1000, new Predicate() {
             public boolean evaluate() throws Exception {
                 CoordinatorJobBean coordJobBean = jpaService.execute(coordJobGetCmd);
                 return !coordJobBean.isPending();

Modified: incubator/oozie/branches/3.1/release-log.txt
URL: http://svn.apache.org/viewvc/incubator/oozie/branches/3.1/release-log.txt?rev=1228449&r1=1228448&r2=1228449&view=diff
==============================================================================
--- incubator/oozie/branches/3.1/release-log.txt (original)
+++ incubator/oozie/branches/3.1/release-log.txt Fri Jan  6 21:58:19 2012
@@ -1,4 +1,5 @@
 -- Oozie 3.1.1 release
+OOZIE-581 Fix unit test failure in TestStatusTransitService.java.
 OOZIE-579 POM file changes for oozie version 3.1.2
 OOZIE-26 Ability to get the log content from Archived file(.gz format)
 OOZIE-554 New filters for all kinds of jobs