From 2874920b6f2a4b1e6e77ddd5093a62ba46e532a9 Mon Sep 17 00:00:00 2001 From: streppel Date: Fri, 10 Apr 2020 13:45:29 -0300 Subject: [PATCH] refactoring TestExecutionSeconds --- scheduler_test.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scheduler_test.go b/scheduler_test.go index 72e10ab9..ca57e28d 100644 --- a/scheduler_test.go +++ b/scheduler_test.go @@ -29,8 +29,8 @@ func TestExecutionSecond(t *testing.T) { func TestExecutionSeconds(t *testing.T) { sched := NewScheduler(time.UTC) jobDone := make(chan bool) - executionTimes := make([]int64, 0, 2) - numberOfIterations := 20 + var executionTimes []int64 + numberOfIterations := 2 sched.Every(2).Seconds().Do(func() { executionTimes = append(executionTimes, time.Now().Unix())