Skip to content

Commit

Permalink
also test start and end
Browse files Browse the repository at this point in the history
Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>
  • Loading branch information
roidelapluie committed Feb 8, 2020
1 parent cbd0eec commit d799078
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions cmd/prometheus/query_log_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,8 @@ func (p *queryLogTest) validateLastQuery(t *testing.T, ql []queryLogLine) {
switch p.origin {
case apiOrigin:
testutil.Equals(t, 5, q.Params.Step)
testutil.Equals(t, "1970-01-01T00:00:00.000Z", q.Params.Start)
testutil.Equals(t, "1970-01-01T01:00:00.000Z", q.Params.End)
default:
testutil.Equals(t, 0, q.Params.Step)
}
Expand Down Expand Up @@ -362,6 +364,8 @@ type queryLogLine struct {
Params struct {
Query string `json:"query"`
Step int `json:"step"`
Start string `json:"start"`
End string `json:"end"`
} `json:"params"`
Request struct {
Path string `json:"path"`
Expand Down

0 comments on commit d799078

Please sign in to comment.