mirror of https://github.com/gin-gonic/gin.git
Compare commits
2 Commits
8ad141c503
...
4d0879a82a
Author | SHA1 | Date |
---|---|---|
ChenPuChu | 4d0879a82a | |
ChenPuChu | fc1a19e6cc |
|
@ -167,7 +167,7 @@ func TestSaveUploadedFileWithPermission(t *testing.T) {
|
|||
require.NoError(t, err)
|
||||
mw.Close()
|
||||
c, _ := CreateTestContext(httptest.NewRecorder())
|
||||
c.Request, _ = http.NewRequest("POST", "/", buf)
|
||||
c.Request, _ = http.NewRequest(http.MethodPost,, "/", buf)
|
||||
c.Request.Header.Set("Content-Type", mw.FormDataContentType())
|
||||
f, err := c.FormFile("file")
|
||||
require.NoError(t, err)
|
||||
|
@ -188,7 +188,7 @@ func TestSaveUploadedFileWithPermissionFailed(t *testing.T) {
|
|||
require.NoError(t, err)
|
||||
mw.Close()
|
||||
c, _ := CreateTestContext(httptest.NewRecorder())
|
||||
c.Request, _ = http.NewRequest("POST", "/", buf)
|
||||
c.Request, _ = http.NewRequest(http.MethodPost, "/", buf)
|
||||
c.Request.Header.Set("Content-Type", mw.FormDataContentType())
|
||||
f, err := c.FormFile("file")
|
||||
require.NoError(t, err)
|
||||
|
|
Loading…
Reference in New Issue