support combo new and old

This commit is contained in:
bel
2021-07-17 22:51:54 -06:00
parent d5ec073f75
commit 9301ddd467
2 changed files with 2 additions and 0 deletions

View File

@@ -153,6 +153,7 @@ func TestToDuration(t *testing.T) {
"simple": {input: "1s", want: time.Second},
"compound": {input: "1m1s", want: time.Minute + time.Second},
"compound:unsorted": {input: "1s1m", want: time.Minute + time.Second},
"compound:extension": {input: "1d1m", want: time.Minute + time.Hour*24},
"extension:day": {input: "1d", want: 24 * time.Hour},
"extension:week": {input: "1w", want: 24 * 7 * time.Hour},
"extension:week,day": {input: "1w1d", want: 24 * 8 * time.Hour},