mirror of
https://github.com/go-gitea/gitea
synced 2025-07-03 09:07:19 +00:00
More db.DefaultContext
refactor (#27265)
Part of #27065 This PR touches functions used in templates. As templates are not static typed, errors are harder to find, but I hope I catch it all. I think some tests from other persons do not hurt.
This commit is contained in:
@ -76,7 +76,7 @@ func TestAPIPullReview(t *testing.T) {
|
||||
assert.EqualValues(t, "a review from a deleted user", reviewComments[0].Body)
|
||||
assert.EqualValues(t, comment.ID, reviewComments[0].ID)
|
||||
assert.EqualValues(t, comment.UpdatedUnix, reviewComments[0].Updated.Unix())
|
||||
assert.EqualValues(t, comment.HTMLURL(), reviewComments[0].HTMLURL)
|
||||
assert.EqualValues(t, comment.HTMLURL(db.DefaultContext), reviewComments[0].HTMLURL)
|
||||
|
||||
// test CreatePullReview
|
||||
req = NewRequestWithJSON(t, http.MethodPost, fmt.Sprintf("/api/v1/repos/%s/%s/pulls/%d/reviews?token=%s", repo.OwnerName, repo.Name, pullIssue.Index, token), &api.CreatePullReviewOptions{
|
||||
|
Reference in New Issue
Block a user