Skip to content

Commit d63f282

Browse files
committed
adjust tests (10)
1 parent 8e53911 commit d63f282

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tests/integration/repo_branch_test.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,9 @@ func prepareRepoPR(t *testing.T, baseSession, headSession *TestSession, baseRepo
200200
func checkRecentlyPushedNewBranches(t *testing.T, session *TestSession, repoPath string, expected []string) {
201201
branches := make([]string, 0, 2)
202202
req := NewRequest(t, "GET", repoPath)
203-
resp := session.MakeRequest(t, req, http.StatusOK)
203+
resp := session.MakeRequest(t, req, http.StatusMovedPermanently)
204+
req = NewRequest(t, "GET", resp.Result().Header.Get("Location"))
205+
resp = MakeRequest(t, req, http.StatusOK)
204206
doc := NewHTMLParser(t, resp.Body)
205207
doc.doc.Find(".ui.positive.message div a").Each(func(index int, branch *goquery.Selection) {
206208
branches = append(branches, branch.Text())

0 commit comments

Comments
 (0)