aboutsummaryrefslogtreecommitdiffstats
path: root/tests/integration/user_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'tests/integration/user_test.go')
-rw-r--r--tests/integration/user_test.go18
1 files changed, 9 insertions, 9 deletions
diff --git a/tests/integration/user_test.go b/tests/integration/user_test.go
index fd7996bf8b..34692d9cab 100644
--- a/tests/integration/user_test.go
+++ b/tests/integration/user_test.go
@@ -217,12 +217,12 @@ func TestGetUserRss(t *testing.T) {
user34 := "the_34-user.with.all.allowedChars"
req := NewRequestf(t, "GET", "/%s.rss", user34)
resp := MakeRequest(t, req, http.StatusOK)
- if assert.EqualValues(t, "application/rss+xml;charset=utf-8", resp.Header().Get("Content-Type")) {
+ if assert.Equal(t, "application/rss+xml;charset=utf-8", resp.Header().Get("Content-Type")) {
rssDoc := NewHTMLParser(t, resp.Body).Find("channel")
title, _ := rssDoc.ChildrenFiltered("title").Html()
- assert.EqualValues(t, "Feed of "the_1-user.with.all.allowedChars"", title)
+ assert.Equal(t, "Feed of "the_1-user.with.all.allowedChars"", title)
description, _ := rssDoc.ChildrenFiltered("description").Html()
- assert.EqualValues(t, "<p dir="auto">some <a href="https://commonmark.org/" rel="nofollow">commonmark</a>!</p>\n", description)
+ assert.Equal(t, "<p dir="auto">some <a href="https://commonmark.org/" rel="nofollow">commonmark</a>!</p>\n", description)
}
req = NewRequestf(t, "GET", "/non-existent-user.rss")
@@ -247,18 +247,18 @@ func TestListStopWatches(t *testing.T) {
stopwatch := unittest.AssertExistsAndLoadBean(t, &issues_model.Stopwatch{UserID: owner.ID})
issue := unittest.AssertExistsAndLoadBean(t, &issues_model.Issue{ID: stopwatch.IssueID})
if assert.Len(t, apiWatches, 1) {
- assert.EqualValues(t, stopwatch.CreatedUnix.AsTime().Unix(), apiWatches[0].Created.Unix())
- assert.EqualValues(t, issue.Index, apiWatches[0].IssueIndex)
- assert.EqualValues(t, issue.Title, apiWatches[0].IssueTitle)
- assert.EqualValues(t, repo.Name, apiWatches[0].RepoName)
- assert.EqualValues(t, repo.OwnerName, apiWatches[0].RepoOwnerName)
+ assert.Equal(t, stopwatch.CreatedUnix.AsTime().Unix(), apiWatches[0].Created.Unix())
+ assert.Equal(t, issue.Index, apiWatches[0].IssueIndex)
+ assert.Equal(t, issue.Title, apiWatches[0].IssueTitle)
+ assert.Equal(t, repo.Name, apiWatches[0].RepoName)
+ assert.Equal(t, repo.OwnerName, apiWatches[0].RepoOwnerName)
assert.Positive(t, apiWatches[0].Seconds)
}
}
func TestUserLocationMapLink(t *testing.T) {
- setting.Service.UserLocationMapURL = "https://example/foo/"
defer tests.PrepareTestEnv(t)()
+ defer test.MockVariableValue(&setting.Service.UserLocationMapURL, "https://example/foo/")()
session := loginUser(t, "user2")
req := NewRequestWithValues(t, "POST", "/user/settings", map[string]string{