diff --git a/pkg/utils/test.go b/pkg/utils/test.go new file mode 100644 index 000000000..e7ebcd7b8 --- /dev/null +++ b/pkg/utils/test.go @@ -0,0 +1,15 @@ +package utils + +import "time" + +func PointerFromFloat64(a float64) *float64 { + return &a +} + +func TimeMustParse(layout, timestamp string) time.Time { + t, err := time.Parse(layout, timestamp) + if err != nil { + panic(err) + } + return t +}