From d63f28289c5c5d1f9f56664277d94ea4ed9ef82c Mon Sep 17 00:00:00 2001 From: 6543 <6543@obermui.de> Date: Thu, 31 Oct 2024 22:48:45 +0100 Subject: [PATCH] adjust tests (10) --- tests/integration/repo_branch_test.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/integration/repo_branch_test.go b/tests/integration/repo_branch_test.go index 6d1cc8afcf..2ddd30a780 100644 --- a/tests/integration/repo_branch_test.go +++ b/tests/integration/repo_branch_test.go @@ -200,7 +200,9 @@ func prepareRepoPR(t *testing.T, baseSession, headSession *TestSession, baseRepo func checkRecentlyPushedNewBranches(t *testing.T, session *TestSession, repoPath string, expected []string) { branches := make([]string, 0, 2) req := NewRequest(t, "GET", repoPath) - resp := session.MakeRequest(t, req, http.StatusOK) + resp := session.MakeRequest(t, req, http.StatusMovedPermanently) + req = NewRequest(t, "GET", resp.Result().Header.Get("Location")) + resp = MakeRequest(t, req, http.StatusOK) doc := NewHTMLParser(t, resp.Body) doc.doc.Find(".ui.positive.message div a").Each(func(index int, branch *goquery.Selection) { branches = append(branches, branch.Text())