1
0
mirror of https://github.com/labstack/echo.git synced 2025-01-12 01:22:21 +02:00

apply go fmt (#1788)

This commit is contained in:
Leo Takaoka 2021-02-27 06:55:00 +09:00 committed by GitHub
parent 45870c75c3
commit d9e235416d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 9 deletions

View File

@ -247,7 +247,6 @@ func TestProxyRewriteRegex(t *testing.T) {
{"/y/foo/bar", http.StatusOK, "/v5/bar/foo"}, {"/y/foo/bar", http.StatusOK, "/v5/bar/foo"},
} }
for _, tc := range testCases { for _, tc := range testCases {
t.Run(tc.requestPath, func(t *testing.T) { t.Run(tc.requestPath, func(t *testing.T) {
req.URL, _ = url.Parse(tc.requestPath) req.URL, _ = url.Parse(tc.requestPath)

View File

@ -163,12 +163,12 @@ func TestEchoRewriteWithRegexRules(t *testing.T) {
{"/y/foo/bar", "/v5/bar/foo"}, {"/y/foo/bar", "/v5/bar/foo"},
} }
for _, tc := range testCases { for _, tc := range testCases {
t.Run(tc.requestPath, func(t *testing.T) { t.Run(tc.requestPath, func(t *testing.T) {
req = httptest.NewRequest(http.MethodGet, tc.requestPath, nil) req = httptest.NewRequest(http.MethodGet, tc.requestPath, nil)
rec = httptest.NewRecorder() rec = httptest.NewRecorder()
e.ServeHTTP(rec, req) e.ServeHTTP(rec, req)
assert.Equal(t, tc.expectPath, req.URL.EscapedPath()) assert.Equal(t, tc.expectPath, req.URL.EscapedPath())
}) })
} }
} }