diff options
Diffstat (limited to 'integrations/branches_test.go')
-rw-r--r-- | integrations/branches_test.go | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/integrations/branches_test.go b/integrations/branches_test.go index 2b9fc8dda5..b2230e7031 100644 --- a/integrations/branches_test.go +++ b/integrations/branches_test.go @@ -57,7 +57,9 @@ func branchAction(t *testing.T, button string) (*HTMLDoc, string) { htmlDoc := NewHTMLParser(t, resp.Body) link, exists := htmlDoc.doc.Find(button).Attr("data-url") - assert.True(t, exists, "The template has changed") + if !assert.True(t, exists, "The template has changed") { + t.Skip() + } req = NewRequestWithValues(t, "POST", link, map[string]string{ "_csrf": getCsrf(t, htmlDoc.doc), @@ -69,7 +71,7 @@ func branchAction(t *testing.T, button string) (*HTMLDoc, string) { req = NewRequest(t, "GET", "/user2/repo1/branches") resp = session.MakeRequest(t, req, http.StatusOK) - return NewHTMLParser(t, resp.Body), url.Query()["name"][0] + return NewHTMLParser(t, resp.Body), url.Query().Get("name") } func getCsrf(t *testing.T, doc *goquery.Document) string { |