You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

15 lines
457 B
Go

2 years ago
package when
import (
"fmt"
"testing"
)
func TestParse(t *testing.T) {
for _, code := range []string{"一个小时后告诉我事情", "三个小时后爱我", "每两个小时提醒我吃饭", "每五个月零二十五天三小时25分15秒告诉我时间", "5月23日上午3点24分12秒打我", "周四上午11点提醒我"} {
a, _ := WhenWithPeriod(code)
//fmt.Println(a.Repeats()[0])
fmt.Println(a.NextTimer(), a.RunCountLimit(), code)
}
}