You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-dev@logging.apache.org by ce...@apache.org on 2004/05/25 10:54:12 UTC

cvs commit: logging-log4j/tests/src/java/org/apache/log4j/scheduler SchedulerTest.java

ceki        2004/05/25 01:54:12

  Modified:    tests/src/java/org/apache/log4j/scheduler SchedulerTest.java
  Log:
  Allow a bit more leeway in SchedulerTest.testPeriodic
  
  Revision  Changes    Path
  1.6       +2 -2      logging-log4j/tests/src/java/org/apache/log4j/scheduler/SchedulerTest.java
  
  Index: SchedulerTest.java
  ===================================================================
  RCS file: /home/cvs/logging-log4j/tests/src/java/org/apache/log4j/scheduler/SchedulerTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- SchedulerTest.java	12 May 2004 15:39:04 -0000	1.5
  +++ SchedulerTest.java	25 May 2004 08:54:12 -0000	1.6
  @@ -185,13 +185,13 @@
       scheduler.schedule(pj, firstOn, period);
   
       int NUM_PERIODS = 10;
  -    sleep(period * NUM_PERIODS);
  +    sleep(period * (NUM_PERIODS+1));
   
       scheduler.shutdown();
   
       long endOfExecution = System.currentTimeMillis();
   
  -    if (pj.count < 10) {
  +    if (pj.count <  NUM_PERIODS) {
         fail(
           "Periodic job executed only " + pj.count + " times. Expected at least"
           + NUM_PERIODS);
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-dev-help@logging.apache.org