mirror of
https://github.com/go-gitea/gitea
synced 2025-07-03 09:07:19 +00:00
Use context parameter in services/repository (#23186)
Use context parameter in `services/repository`. And use `cache.WithCacheContext(ctx)` to generate push action history feeds. Fix #23160
This commit is contained in:
@ -356,7 +356,7 @@ func TestConflictChecking(t *testing.T) {
|
||||
user := unittest.AssertExistsAndLoadBean(t, &user_model.User{ID: 2})
|
||||
|
||||
// Create new clean repo to test conflict checking.
|
||||
baseRepo, err := repo_service.CreateRepository(user, user, repo_module.CreateRepoOptions{
|
||||
baseRepo, err := repo_service.CreateRepository(db.DefaultContext, user, user, repo_module.CreateRepoOptions{
|
||||
Name: "conflict-checking",
|
||||
Description: "Tempo repo",
|
||||
AutoInit: true,
|
||||
|
@ -80,7 +80,7 @@ func TestAPIPullUpdateByRebase(t *testing.T) {
|
||||
}
|
||||
|
||||
func createOutdatedPR(t *testing.T, actor, forkOrg *user_model.User) *issues_model.PullRequest {
|
||||
baseRepo, err := repo_service.CreateRepository(actor, actor, repo_module.CreateRepoOptions{
|
||||
baseRepo, err := repo_service.CreateRepository(db.DefaultContext, actor, actor, repo_module.CreateRepoOptions{
|
||||
Name: "repo-pr-update",
|
||||
Description: "repo-tmp-pr-update description",
|
||||
AutoInit: true,
|
||||
|
Reference in New Issue
Block a user