Fixing test on CI servers.

git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@1383308 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Claus Ibsen 2012-09-11 09:21:36 +00:00
parent b968c0c9b2
commit 49bb4bf494
2 changed files with 5 additions and 3 deletions

View File

@ -78,7 +78,8 @@ public class JobSchedulerTest {
String str = new String("test1");
scheduler.schedule("id:1", new ByteSequence(str.getBytes()), cronTab, 0, 0, 0);
assertTrue(latch.await(60, TimeUnit.SECONDS));
// need a little slack so go over 60 seconds
assertTrue(latch.await(70, TimeUnit.SECONDS));
assertEquals(0, latch.getCount());
}

View File

@ -50,7 +50,8 @@ public class SecurityJMXTest extends TestCase {
public void setUp() throws Exception {
broker = createBroker();
broker.waitUntilStarted();
Thread.sleep(500);
Thread.sleep(1000);
}
public void tearDown() throws Exception {
@ -81,7 +82,7 @@ public class SecurityJMXTest extends TestCase {
headers.put("JMSDeliveryMode", Integer.toString(DeliveryMode.PERSISTENT));
String msgId = queueMbean.sendTextMessage(headers, "test", "system", "manager");
// allow message to expire on the queue
TimeUnit.SECONDS.sleep(3);
TimeUnit.SECONDS.sleep(4);
Connection c = new ActiveMQConnectionFactory("vm://localhost").createConnection("system", "manager");
c.start();