fix test failure on slow ci boxes

This commit is contained in:
Dejan Bosanac 2014-12-22 12:03:36 +01:00
parent a090472942
commit d91bdc4cff
1 changed files with 2 additions and 2 deletions

View File

@ -81,7 +81,7 @@ public class AMQ2584Test extends org.apache.activemq.TestSupport {
@Test(timeout = 120000)
public void testSize() throws Exception {
int messages = 1000;
CountDownLatch redeliveryConsumerLatch = new CountDownLatch((messages*3) -1);
CountDownLatch redeliveryConsumerLatch = new CountDownLatch((messages*3));
openConsumer(redeliveryConsumerLatch);
assertEquals(0, broker.getAdminView().getStorePercentUsage());
@ -101,7 +101,7 @@ public class AMQ2584Test extends org.apache.activemq.TestSupport {
closeConsumer();
// consume from DLQ
final CountDownLatch received = new CountDownLatch(messages -1);
final CountDownLatch received = new CountDownLatch(messages);
consumerConnection = (ActiveMQConnection) createConnection();
Session dlqSession = consumerConnection.createSession(false, Session.AUTO_ACKNOWLEDGE);
MessageConsumer dlqConsumer = dlqSession.createConsumer(new ActiveMQQueue("ActiveMQ.DLQ"));