Blame SOURCES/006-fix-gtime-test-32bit.patch
|
|
77b9e5 |
diff --git a/pkg/components/gtime/gtime_test.go b/pkg/components/gtime/gtime_test.go
|
|
|
77b9e5 |
index 0b1b23a1db..eb9fe718c7 100644
|
|
|
77b9e5 |
--- a/pkg/components/gtime/gtime_test.go
|
|
|
77b9e5 |
+++ b/pkg/components/gtime/gtime_test.go
|
|
|
77b9e5 |
@@ -20,9 +20,9 @@ func TestParseInterval(t *testing.T) {
|
|
|
77b9e5 |
{inp: "1d", duration: 24 * time.Hour},
|
|
|
77b9e5 |
{inp: "1w", duration: 168 * time.Hour},
|
|
|
77b9e5 |
{inp: "2w", duration: 2 * 168 * time.Hour},
|
|
|
77b9e5 |
- {inp: "1M", duration: time.Duration(daysInMonth * 24 * int(time.Hour))},
|
|
|
77b9e5 |
- {inp: "1y", duration: time.Duration(daysInYear * 24 * int(time.Hour))},
|
|
|
77b9e5 |
- {inp: "5y", duration: time.Duration(calculateDays5y() * 24 * int(time.Hour))},
|
|
|
77b9e5 |
+ {inp: "1M", duration: time.Duration(int64(daysInMonth) * 24 * int64(time.Hour))},
|
|
|
77b9e5 |
+ {inp: "1y", duration: time.Duration(int64(daysInYear) * 24 * int64(time.Hour))},
|
|
|
77b9e5 |
+ {inp: "5y", duration: time.Duration(int64(calculateDays5y()) * 24 * int64(time.Hour))},
|
|
|
77b9e5 |
{inp: "invalid-duration", err: regexp.MustCompile(`^time: invalid duration "?invalid-duration"?$`)},
|
|
|
77b9e5 |
}
|
|
|
77b9e5 |
for i, tc := range tcs {
|