From 9fdcbb69378c5397d7ca339e7d9db909b4f34ea9 Mon Sep 17 00:00:00 2001 From: Izabella Raulin Date: Mon, 19 Jun 2017 10:11:26 +0200 Subject: [PATCH] Fixed #1649 - incremented interval for tested task to 20ms --- pkg/schedule/windowed_schedule_medium_test.go | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/pkg/schedule/windowed_schedule_medium_test.go b/pkg/schedule/windowed_schedule_medium_test.go index f9e7a079f..9b4231995 100644 --- a/pkg/schedule/windowed_schedule_medium_test.go +++ b/pkg/schedule/windowed_schedule_medium_test.go @@ -34,7 +34,7 @@ func TestWindowedSchedule(t *testing.T) { log.SetLevel(log.DebugLevel) Convey("Windowed Schedule expected to run forever", t, func() { - interval := time.Millisecond * 10 + interval := time.Millisecond * 20 // set start and stop are nil, and the count is zero what means no limits w := NewWindowedSchedule(interval, nil, nil, 0) @@ -102,8 +102,8 @@ func TestWindowedSchedule(t *testing.T) { Convey("Nominal windowed Schedule", t, func() { Convey("without misses", func() { startWait := time.Millisecond * 50 - windowSize := time.Millisecond * 200 - interval := time.Millisecond * 10 + windowSize := time.Millisecond * 400 + interval := time.Millisecond * 20 start := time.Now().Add(startWait) stop := time.Now().Add(startWait + windowSize) @@ -149,8 +149,8 @@ func TestWindowedSchedule(t *testing.T) { }) Convey("with a few misses", func() { startWait := time.Millisecond * 50 - windowSize := time.Millisecond * 200 - interval := time.Millisecond * 10 + windowSize := time.Millisecond * 400 + interval := time.Millisecond * 20 start := time.Now().Add(startWait) stop := time.Now().Add(startWait + windowSize) @@ -204,8 +204,8 @@ func TestWindowedSchedule(t *testing.T) { }) Convey("started in the past", func() { startWait := time.Millisecond * -200 - windowSize := time.Millisecond * 400 - interval := time.Millisecond * 10 + windowSize := time.Millisecond * 600 + interval := time.Millisecond * 20 start := time.Now().Add(startWait) stop := time.Now().Add(startWait + windowSize) @@ -258,7 +258,7 @@ func TestWindowedSchedule(t *testing.T) { }) Convey("start without stop", func() { startWait := time.Millisecond * 50 - interval := time.Millisecond * 10 + interval := time.Millisecond * 20 start := time.Now().Add(startWait) w := NewWindowedSchedule( @@ -290,8 +290,8 @@ func TestWindowedSchedule(t *testing.T) { ) }) Convey("stop without start", func() { - windowSize := time.Millisecond * 200 - interval := time.Millisecond * 10 + windowSize := time.Millisecond * 400 + interval := time.Millisecond * 20 stop := time.Now().Add(windowSize) w := NewWindowedSchedule(