Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions prometheus/collectors/go_collector_latest_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ func TestWithGoCollectorDefault(t *testing.T) {
expected := append(withBaseMetrics(memstatMetrics), defaultRuntimeMetrics...)
sort.Strings(expected)
if diff := cmp.Diff(got, expected); diff != "" {
t.Errorf("[IMPORTANT, those are default metrics, can't change in 1.x] missmatch (-want +got):\n%s", diff)
t.Errorf("[IMPORTANT, those are default metrics, can't change in 1.x] mismatch (-want +got):\n%s", diff)
}
}

Expand All @@ -132,7 +132,7 @@ func TestWithGoCollectorMemStatsMetricsDisabled(t *testing.T) {
}

if diff := cmp.Diff(got, withBaseMetrics(defaultRuntimeMetrics)); diff != "" {
t.Errorf("missmatch (-want +got):\n%s", diff)
t.Errorf("mismatch (-want +got):\n%s", diff)
}
}

Expand Down Expand Up @@ -190,7 +190,7 @@ func TestGoCollectorAllowList(t *testing.T) {
}

if diff := cmp.Diff(got, test.expected); diff != "" {
t.Errorf("missmatch (-want +got):\n%s", diff)
t.Errorf("mismatch (-want +got):\n%s", diff)
}
})
}
Expand Down Expand Up @@ -252,7 +252,7 @@ func TestGoCollectorDenyList(t *testing.T) {
}

if diff := cmp.Diff(got, test.expected); diff != "" {
t.Errorf("missmatch (-want +got):\n%s", diff)
t.Errorf("mismatch (-want +got):\n%s", diff)
}
})
}
Expand Down
8 changes: 4 additions & 4 deletions prometheus/collectors/version/version_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,13 @@ func TestGoVersionCollector(t *testing.T) {
}

if diff := cmp.Diff(lk, defaultLabels); diff != "" {
t.Errorf("missmatch (-want +got):\n%s", diff)
t.Errorf("mismatch (-want +got):\n%s", diff)
}

}

if diff := cmp.Diff(got, []string{"foo_build_info"}); diff != "" {
t.Errorf("missmatch (-want +got):\n%s", diff)
t.Errorf("mismatch (-want +got):\n%s", diff)
}
}

Expand Down Expand Up @@ -103,12 +103,12 @@ func TestGoVersionCollectorWithLabels(t *testing.T) {
labels := append(defaultLabels, "z-mylabel")

if diff := cmp.Diff(lk, labels); diff != "" {
t.Errorf("missmatch (-want +got):\n%s", diff)
t.Errorf("mismatch (-want +got):\n%s", diff)
}

}

if diff := cmp.Diff(got, []string{"foo_build_info"}); diff != "" {
t.Errorf("missmatch (-want +got):\n%s", diff)
t.Errorf("mismatch (-want +got):\n%s", diff)
}
}
2 changes: 1 addition & 1 deletion prometheus/histogram.go
Original file line number Diff line number Diff line change
Expand Up @@ -970,7 +970,7 @@ func (h *histogram) maybeReset(
// We are using the possibly mocked h.now() rather than
// time.Since(h.lastResetTime) to enable testing.
if h.nativeHistogramMinResetDuration == 0 || // No reset configured.
h.resetScheduled || // Do not interefere if a reset is already scheduled.
h.resetScheduled || // Do not interfere if a reset is already scheduled.
h.now().Sub(h.lastResetTime) < h.nativeHistogramMinResetDuration {
return false
}
Expand Down
2 changes: 1 addition & 1 deletion prometheus/internal/difflib.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ type OpCode struct {
// notion, pairing up elements that appear uniquely in each sequence.
// That, and the method here, appear to yield more intuitive difference
// reports than does diff. This method appears to be the least vulnerable
// to synching up on blocks of "junk lines", though (like blank lines in
// to syncing up on blocks of "junk lines", though (like blank lines in
// ordinary text files, or maybe "<P>" lines in HTML files). That may be
// because this is the only method of the 3 that has a *concept* of
// "junk" <wink>.
Expand Down
Loading