diff options
author | wxiaoguang <wxiaoguang@gmail.com> | 2023-04-15 02:18:28 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-04-14 14:18:28 -0400 |
commit | cfe3d6e9b507a9331328e55ff98a1f582abae185 (patch) | |
tree | 94b035bd2859291a16edda27822b570bdd611a35 /tests | |
parent | b667634b32e240f3f3260ab7e304f72f4ff75659 (diff) | |
download | gitea-cfe3d6e9b507a9331328e55ff98a1f582abae185.tar.gz gitea-cfe3d6e9b507a9331328e55ff98a1f582abae185.zip |
Make more functions use ctx instead of db.DefaultContext (#24068)
Continue the "ctx refactoring" work.
There are still a lot db.DefaultContext, incorrect context could cause
database deadlock errors.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/integration/api_pull_test.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/integration/api_pull_test.go b/tests/integration/api_pull_test.go index 4427c610bf..4b25f97ddd 100644 --- a/tests/integration/api_pull_test.go +++ b/tests/integration/api_pull_test.go @@ -67,7 +67,7 @@ func TestAPIMergePullWIP(t *testing.T) { owner := unittest.AssertExistsAndLoadBean(t, &user_model.User{ID: repo.OwnerID}) pr := unittest.AssertExistsAndLoadBean(t, &issues_model.PullRequest{Status: issues_model.PullRequestStatusMergeable}, unittest.Cond("has_merged = ?", false)) pr.LoadIssue(db.DefaultContext) - issue_service.ChangeTitle(pr.Issue, owner, setting.Repository.PullRequest.WorkInProgressPrefixes[0]+" "+pr.Issue.Title) + issue_service.ChangeTitle(db.DefaultContext, pr.Issue, owner, setting.Repository.PullRequest.WorkInProgressPrefixes[0]+" "+pr.Issue.Title) // force reload pr.LoadAttributes(db.DefaultContext) |