From 9706f654a49b35df7a9589521584759bbc577e48 Mon Sep 17 00:00:00 2001 From: Bosanac Dejan Date: Wed, 18 Apr 2012 11:47:25 +0000 Subject: [PATCH] JobSchedulerStoreTest - fix test, don't allow jobs to start scheduling on slow machines git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@1327457 13f79535-47bb-0310-9956-ffa450edef68 --- .../broker/scheduler/JobSchedulerStoreTest.java | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/activemq-core/src/test/java/org/apache/activemq/broker/scheduler/JobSchedulerStoreTest.java b/activemq-core/src/test/java/org/apache/activemq/broker/scheduler/JobSchedulerStoreTest.java index 219164ab93..ed3c92c184 100644 --- a/activemq-core/src/test/java/org/apache/activemq/broker/scheduler/JobSchedulerStoreTest.java +++ b/activemq-core/src/test/java/org/apache/activemq/broker/scheduler/JobSchedulerStoreTest.java @@ -16,13 +16,14 @@ */ package org.apache.activemq.broker.scheduler; -import java.io.File; -import java.util.ArrayList; -import java.util.List; import junit.framework.TestCase; import org.apache.activemq.util.IOHelper; import org.apache.kahadb.util.ByteSequence; +import java.io.File; +import java.util.ArrayList; +import java.util.List; + public class JobSchedulerStoreTest extends TestCase { public void testRestart() throws Exception { @@ -40,9 +41,9 @@ public class JobSchedulerStoreTest extends TestCase { } JobScheduler js = store.getJobScheduler("test"); int count = 0; - long startTime = 10000; + long startTime = 10 * 60 * 1000; long period = startTime; for (ByteSequence job:list) { - js.schedule("id:"+(count++), job,"",startTime,10000,-1); + js.schedule("id:"+(count++), job, "", startTime, period, -1); } Listtest = js.getAllJobs(); assertEquals(list.size(),test.size());