activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dej...@apache.org
Subject svn commit: r819493 - /activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/AMQ2413Test.java
Date Mon, 28 Sep 2009 10:37:58 GMT
Author: dejanb
Date: Mon Sep 28 10:37:57 2009
New Revision: 819493

URL: http://svn.apache.org/viewvc?rev=819493&view=rev
Log:
https://issues.apache.org/activemq/browse/AMQ-2413 - prevent test failures on slow machines

Modified:
    activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/AMQ2413Test.java

Modified: activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/AMQ2413Test.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/AMQ2413Test.java?rev=819493&r1=819492&r2=819493&view=diff
==============================================================================
--- activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/AMQ2413Test.java (original)
+++ activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/AMQ2413Test.java Mon
Sep 28 10:37:57 2009
@@ -183,6 +183,7 @@
         try {
             while (count.get() < SEND_COUNT) {
                 if (!receivedMessages.tryAcquire(HANG_THRESHOLD, TimeUnit.SECONDS)) {
+                    if (count.get() == SEND_COUNT) break;
                     throw new TimeoutException("Message not received for more than " + HANG_THRESHOLD
+ " seconds");
                 }
             }



Mime
View raw message