diff options
author | Ethan Koenig <etk39@cornell.edu> | 2017-06-24 20:15:42 -0400 |
---|---|---|
committer | Lunny Xiao <xiaolunwen@gmail.com> | 2017-06-25 08:15:42 +0800 |
commit | f64c232953d13043b262dc8da55acb3738e58d15 (patch) | |
tree | 9f1e88ff351e10be789783254fa51f8fe9c342a7 /integrations/pull_merge_test.go | |
parent | 3ffedeab03a80e7345823d118042d17a3e3d9b52 (diff) | |
download | gitea-f64c232953d13043b262dc8da55acb3738e58d15.tar.gz gitea-f64c232953d13043b262dc8da55acb3738e58d15.zip |
Improve integration test helper functions (#2049)
Set request headers in helper functions, and new helper for requests with string-formatted URLs
Diffstat (limited to 'integrations/pull_merge_test.go')
-rw-r--r-- | integrations/pull_merge_test.go | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/integrations/pull_merge_test.go b/integrations/pull_merge_test.go index da3103bd33..9249f39bd6 100644 --- a/integrations/pull_merge_test.go +++ b/integrations/pull_merge_test.go @@ -25,7 +25,6 @@ func testPullMerge(t *testing.T, session *TestSession, user, repo, pullnum strin req = NewRequestWithValues(t, "POST", link, map[string]string{ "_csrf": htmlDoc.GetCSRF(), }) - req.Header.Add("Content-Type", "application/x-www-form-urlencoded") resp = session.MakeRequest(t, req) assert.EqualValues(t, http.StatusFound, resp.HeaderCode) @@ -44,7 +43,6 @@ func testPullCleanUp(t *testing.T, session *TestSession, user, repo, pullnum str req = NewRequestWithValues(t, "POST", link, map[string]string{ "_csrf": htmlDoc.GetCSRF(), }) - req.Header.Add("Content-Type", "application/x-www-form-urlencoded") resp = session.MakeRequest(t, req) assert.EqualValues(t, http.StatusOK, resp.HeaderCode) |