summaryrefslogtreecommitdiffstats
path: root/integrations/links_test.go
diff options
context:
space:
mode:
authorMorlinest <morlinest@gmail.com>2017-11-02 23:01:22 +0100
committerLauris BH <lauris@nix.lv>2017-11-03 00:01:22 +0200
commit1f04c00e2fb8bb3c5c300712e7c1d581db4404d7 (patch)
tree8b1a4174e5e2e3f47993a9af2aa23c707177f399 /integrations/links_test.go
parent529f9d03ce578555d87657265cb1b25d7b81ecf6 (diff)
downloadgitea-1f04c00e2fb8bb3c5c300712e7c1d581db4404d7.tar.gz
gitea-1f04c00e2fb8bb3c5c300712e7c1d581db4404d7.zip
Fix redirect url of legacy commits route (#2825)
Diffstat (limited to 'integrations/links_test.go')
-rw-r--r--integrations/links_test.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/integrations/links_test.go b/integrations/links_test.go
index 7eaf1c51ef..e1213a2edc 100644
--- a/integrations/links_test.go
+++ b/integrations/links_test.go
@@ -7,8 +7,10 @@ package integrations
import (
"fmt"
"net/http"
+ "path"
"testing"
+ "code.gitea.io/gitea/modules/setting"
api "code.gitea.io/sdk/gitea"
"github.com/stretchr/testify/assert"
@@ -50,7 +52,7 @@ func TestRedirectsNoLogin(t *testing.T) {
for link, redirectLink := range redirects {
req := NewRequest(t, "GET", link)
resp := MakeRequest(t, req, http.StatusFound)
- assert.EqualValues(t, redirectLink, RedirectURL(t, resp))
+ assert.EqualValues(t, path.Join(setting.AppSubURL, redirectLink), RedirectURL(t, resp))
}
}