diff --git a/expfmt/encode.go b/expfmt/encode.go index 547c05ee4..6af7e0014 100644 --- a/expfmt/encode.go +++ b/expfmt/encode.go @@ -61,7 +61,7 @@ func (ec encoderCloser) Close() error { // appropriate accepted type is found, FmtText is returned (which is the // Prometheus text format). This function will never negotiate FmtOpenMetrics, // as the support is still experimental. To include the option to negotiate -// FmtOpenMetrics, use NegotiateOpenMetrics. +// FmtOpenMetrics, use NegotiateIncludingOpenMetrics. func Negotiate(h http.Header) Format { escapingScheme := Format(fmt.Sprintf("; escaping=%s", Format(model.NameEscapingScheme.String()))) for _, ac := range goautoneg.ParseAccept(h.Get(hdrAccept)) { diff --git a/expfmt/encode_test.go b/expfmt/encode_test.go index df0b2ed42..b7d3418f7 100644 --- a/expfmt/encode_test.go +++ b/expfmt/encode_test.go @@ -99,7 +99,7 @@ func TestNegotiate(t *testing.T) { } } -func TestNegotiateOpenMetrics(t *testing.T) { +func TestNegotiateIncludingOpenMetrics(t *testing.T) { acceptValuePrefix := "application/vnd.google.protobuf;proto=io.prometheus.client.MetricFamily" tests := []struct { name string