Skip to content

Commit

Permalink
apply go fmt (#1788)
Browse files Browse the repository at this point in the history
  • Loading branch information
takaokanbe committed Feb 26, 2021
1 parent 45870c7 commit d9e2354
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 9 deletions.
1 change: 0 additions & 1 deletion middleware/proxy_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,6 @@ func TestProxyRewriteRegex(t *testing.T) {
{"/y/foo/bar", http.StatusOK, "/v5/bar/foo"},
}


for _, tc := range testCases {
t.Run(tc.requestPath, func(t *testing.T) {
req.URL, _ = url.Parse(tc.requestPath)
Expand Down
16 changes: 8 additions & 8 deletions middleware/rewrite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -163,12 +163,12 @@ func TestEchoRewriteWithRegexRules(t *testing.T) {
{"/y/foo/bar", "/v5/bar/foo"},
}

for _, tc := range testCases {
t.Run(tc.requestPath, func(t *testing.T) {
req = httptest.NewRequest(http.MethodGet, tc.requestPath, nil)
rec = httptest.NewRecorder()
e.ServeHTTP(rec, req)
assert.Equal(t, tc.expectPath, req.URL.EscapedPath())
})
}
for _, tc := range testCases {
t.Run(tc.requestPath, func(t *testing.T) {
req = httptest.NewRequest(http.MethodGet, tc.requestPath, nil)
rec = httptest.NewRecorder()
e.ServeHTTP(rec, req)
assert.Equal(t, tc.expectPath, req.URL.EscapedPath())
})
}
}

0 comments on commit d9e2354

Please sign in to comment.