Skip to content

Commit d972de7

Browse files
authored
chore: enable usestdlibvars linter (#772)
Signed-off-by: Matthieu MOREL <[email protected]>
1 parent 2d148dd commit d972de7

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

.golangci.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ linters:
1414
- govet
1515
- misspell
1616
- testifylint
17+
- usestdlibvars
1718

1819
settings:
1920
errcheck:

providers/prometheus/server_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ func (s *ServerInterceptorTestSuite) TestContextCancelledTreatedAsStatus() {
175175
// Order of matching label vales does not matter.
176176
func fetchPrometheusLines(t *testing.T, reg prometheus.Gatherer, metricName string, matchingLabelValues ...string) []string {
177177
resp := httptest.NewRecorder()
178-
req, err := http.NewRequest("GET", "/", http.NoBody)
178+
req, err := http.NewRequest(http.MethodGet, "/", http.NoBody)
179179
require.NoError(t, err, "failed creating request for Prometheus handler")
180180

181181
promhttp.HandlerFor(reg, promhttp.HandlerOpts{}).ServeHTTP(resp, req)

0 commit comments

Comments
 (0)