diff --git a/.e2e/gotest/e2e_test.go b/.e2e/gotest/e2e_test.go index dc795f6..538ffee 100644 --- a/.e2e/gotest/e2e_test.go +++ b/.e2e/gotest/e2e_test.go @@ -59,7 +59,7 @@ func TestE2E(t *testing.T) { name: "valid path - " + *baseUrl + "/rest/v1/2.2.2.2", url: "" + *baseUrl + "/rest/v1/2.2.2.2", method: "GET", - want: []byte(`{"ip":"2.2.2.2","country_code":"FR","country_name":"France","city":"Paris","latitude":48.8566,"longitude":2.35222}`), + want: []byte(`{"ip":"2.2.2.2","country_code":"FR","country_name":"France","city":"Issy-les-Moulineaux","latitude":48.8309,"longitude":2.26582}`), code: http.StatusOK, }, { diff --git a/.e2e/gotest/metrics_test.go b/.e2e/gotest/metrics_test.go index ae01e22..d8c91df 100644 --- a/.e2e/gotest/metrics_test.go +++ b/.e2e/gotest/metrics_test.go @@ -26,7 +26,7 @@ func parseMF(r io.Reader) (map[string]*dto.MetricFamily, error) { func populateMetrics() error { requests := []struct { ip string - }{{ip: "1.1.1.1"},{ip: "2.2.2.2"},{ip: "3.3.3.3"},{ip: "4.4.4.4"},{ip: "5.5.5.5"},{ip: "6.6.6.6"},} + }{{ip: "1.1.1.1"}, {ip: "2.2.2.2"}, {ip: "3.3.3.3"}, {ip: "4.4.4.4"}, {ip: "5.5.5.5"}, {ip: "6.6.6.6"}} client := &http.Client{Timeout: 5 * time.Second} @@ -48,7 +48,7 @@ func populateMetrics() error { func TestWithMetricsEnabled(t *testing.T) { err := populateMetrics() if err != nil { - t.Fatalf(err.Error()) + t.Fatal(err.Error()) } client := &http.Client{Timeout: 5 * time.Second} @@ -77,7 +77,7 @@ func TestWithMetricsEnabled(t *testing.T) { data = append(data, '\n') mf, err := parseMF(bytes.NewReader(data)) if err != nil { - t.Fatalf(err.Error()) + t.Fatal(err.Error()) } assert.NoError(t, err) diff --git a/go.mod b/go.mod index baf6a18..009f510 100644 --- a/go.mod +++ b/go.mod @@ -11,7 +11,7 @@ require ( github.com/gorilla/handlers v1.5.2 github.com/julienschmidt/httprouter v1.3.0 github.com/justinas/alice v1.2.0 - github.com/prometheus/client_golang v1.20.4 + github.com/prometheus/client_golang v1.20.5 github.com/prometheus/common v0.59.1 // indirect github.com/rs/xid v1.6.0 github.com/rs/zerolog v1.33.0 diff --git a/go.sum b/go.sum index 7f60fd1..325a3c6 100644 --- a/go.sum +++ b/go.sum @@ -100,8 +100,8 @@ github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINE github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 h1:Jamvg5psRIccs7FGNTlIRMkT8wgtp5eCXdBlqhYGL6U= github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/prometheus/client_golang v1.20.4 h1:Tgh3Yr67PaOv/uTqloMsCEdeuFTatm5zIq5+qNN23vI= -github.com/prometheus/client_golang v1.20.4/go.mod h1:PIEt8X02hGcP8JWbeHyeZ53Y/jReSnHgO035n//V5WE= +github.com/prometheus/client_golang v1.20.5 h1:cxppBPuYhUnsO6yo/aoRol4L7q7UFfdm+bR9r+8l63Y= +github.com/prometheus/client_golang v1.20.5/go.mod h1:PIEt8X02hGcP8JWbeHyeZ53Y/jReSnHgO035n//V5WE= github.com/prometheus/client_model v0.6.1 h1:ZKSh/rekM+n3CeS952MLRAdFwIKqeY8b62p8ais2e9E= github.com/prometheus/client_model v0.6.1/go.mod h1:OrxVMOVHjw3lKMa8+x6HeMGkHMQyHDk9E3jmP2AmGiY= github.com/prometheus/common v0.59.1 h1:LXb1quJHWm1P6wq/U824uxYi4Sg0oGvNeUm1z5dJoX0=