Fixes silly issues created by me
This commit is contained in:
parent
2d721136c2
commit
9032d61516
|
@ -32,7 +32,6 @@ public class TimeValueScheduleTests extends ESTestCase {
|
||||||
public void testNextScheduledTimeFirstTriggerNotReached() {
|
public void testNextScheduledTimeFirstTriggerNotReached() {
|
||||||
long start = randomNonNegativeLong();
|
long start = randomNonNegativeLong();
|
||||||
TimeValue interval = createRandomTimeValue();
|
TimeValue interval = createRandomTimeValue();
|
||||||
System.out.println("interval: " + interval);
|
|
||||||
long triggerTime = start + interval.millis();
|
long triggerTime = start + interval.millis();
|
||||||
long now = start + randomLongBetween(0, interval.millis() - 1);
|
long now = start + randomLongBetween(0, interval.millis() - 1);
|
||||||
TimeValueSchedule schedule = new TimeValueSchedule(interval);
|
TimeValueSchedule schedule = new TimeValueSchedule(interval);
|
||||||
|
@ -42,7 +41,6 @@ public class TimeValueScheduleTests extends ESTestCase {
|
||||||
public void testNextScheduledTimeAtFirstInterval() {
|
public void testNextScheduledTimeAtFirstInterval() {
|
||||||
long start = randomNonNegativeLong();
|
long start = randomNonNegativeLong();
|
||||||
TimeValue interval = createRandomTimeValue();
|
TimeValue interval = createRandomTimeValue();
|
||||||
System.out.println("interval: " + interval);
|
|
||||||
long triggerTime = start + 2 * interval.millis();
|
long triggerTime = start + 2 * interval.millis();
|
||||||
long now = start + interval.millis();
|
long now = start + interval.millis();
|
||||||
TimeValueSchedule schedule = new TimeValueSchedule(interval);
|
TimeValueSchedule schedule = new TimeValueSchedule(interval);
|
||||||
|
@ -52,7 +50,6 @@ public class TimeValueScheduleTests extends ESTestCase {
|
||||||
public void testNextScheduledTimeAtStartTime() {
|
public void testNextScheduledTimeAtStartTime() {
|
||||||
long start = randomNonNegativeLong();
|
long start = randomNonNegativeLong();
|
||||||
TimeValue interval = createRandomTimeValue();
|
TimeValue interval = createRandomTimeValue();
|
||||||
System.out.println("interval: " + interval);
|
|
||||||
long triggerTime = start + interval.millis();
|
long triggerTime = start + interval.millis();
|
||||||
TimeValueSchedule schedule = new TimeValueSchedule(interval);
|
TimeValueSchedule schedule = new TimeValueSchedule(interval);
|
||||||
assertEquals(triggerTime, schedule.nextScheduledTimeAfter(start, start));
|
assertEquals(triggerTime, schedule.nextScheduledTimeAfter(start, start));
|
||||||
|
@ -61,7 +58,6 @@ public class TimeValueScheduleTests extends ESTestCase {
|
||||||
public void testNextScheduledTimeAfterFirstTrigger() {
|
public void testNextScheduledTimeAfterFirstTrigger() {
|
||||||
long start = randomNonNegativeLong();
|
long start = randomNonNegativeLong();
|
||||||
TimeValue interval = createRandomTimeValue();
|
TimeValue interval = createRandomTimeValue();
|
||||||
System.out.println("interval: " + interval);
|
|
||||||
long numberIntervalsPassed = randomLongBetween(0, 10000);
|
long numberIntervalsPassed = randomLongBetween(0, 10000);
|
||||||
long triggerTime = start + (numberIntervalsPassed + 1) * interval.millis();
|
long triggerTime = start + (numberIntervalsPassed + 1) * interval.millis();
|
||||||
long now = start
|
long now = start
|
||||||
|
|
Loading…
Reference in New Issue