Add the task service. Ready to tidy the go modules.
This commit is contained in:
18
code/test/cron_test.go
Normal file
18
code/test/cron_test.go
Normal file
@ -0,0 +1,18 @@
|
||||
package test
|
||||
|
||||
import (
|
||||
"github.com/robfig/cron/v3"
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestValidateCron(t *testing.T) {
|
||||
|
||||
spec := "*/1 * * * * ?"
|
||||
_, err := cron.Parse(spec)
|
||||
if err != nil {
|
||||
t.Error(err)
|
||||
} else {
|
||||
t.Logf("%s passed\n", spec)
|
||||
}
|
||||
|
||||
}
|
Reference in New Issue
Block a user