Skip to content

Commit 76cc370

Browse files
committed
remove enable action
1 parent 5b091c7 commit 76cc370

File tree

1 file changed

+0
-29
lines changed

1 file changed

+0
-29
lines changed

tests/integration/actions_trigger_test.go

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ import (
1717
issues_model "code.gitea.io/gitea/models/issues"
1818
"code.gitea.io/gitea/models/perm"
1919
repo_model "code.gitea.io/gitea/models/repo"
20-
unit_model "code.gitea.io/gitea/models/unit"
2120
"code.gitea.io/gitea/models/unittest"
2221
user_model "code.gitea.io/gitea/models/user"
2322
actions_module "code.gitea.io/gitea/modules/actions"
@@ -56,13 +55,6 @@ func TestPullRequestTargetEvent(t *testing.T) {
5655
assert.NoError(t, err)
5756
assert.NotEmpty(t, baseRepo)
5857

59-
// enable actions
60-
err = repo_service.UpdateRepositoryUnits(db.DefaultContext, baseRepo, []repo_model.RepoUnit{{
61-
RepoID: baseRepo.ID,
62-
Type: unit_model.TypeActions,
63-
}}, nil)
64-
assert.NoError(t, err)
65-
6658
// add user4 as the collaborator
6759
ctx := NewAPITestContext(t, baseRepo.OwnerName, baseRepo.Name, auth_model.AccessTokenScopeWriteRepository)
6860
t.Run("AddUser4AsCollaboratorWithReadAccess", doAPIAddCollaborator(ctx, "user4", perm.AccessModeRead))
@@ -232,13 +224,6 @@ func TestSkipCI(t *testing.T) {
232224
assert.NoError(t, err)
233225
assert.NotEmpty(t, repo)
234226

235-
// enable actions
236-
err = repo_service.UpdateRepositoryUnits(db.DefaultContext, repo, []repo_model.RepoUnit{{
237-
RepoID: repo.ID,
238-
Type: unit_model.TypeActions,
239-
}}, nil)
240-
assert.NoError(t, err)
241-
242227
// add workflow file to the repo
243228
addWorkflowToBaseResp, err := files_service.ChangeRepoFiles(git.DefaultContext, repo, user2, &files_service.ChangeRepoFilesOptions{
244229
Files: []*files_service.ChangeRepoFile{
@@ -358,13 +343,6 @@ func TestCreateDeleteRefEvent(t *testing.T) {
358343
assert.NoError(t, err)
359344
assert.NotEmpty(t, repo)
360345

361-
// enable actions
362-
err = repo_service.UpdateRepositoryUnits(db.DefaultContext, repo, []repo_model.RepoUnit{{
363-
RepoID: repo.ID,
364-
Type: unit_model.TypeActions,
365-
}}, nil)
366-
assert.NoError(t, err)
367-
368346
// add workflow file to the repo
369347
addWorkflowToBaseResp, err := files_service.ChangeRepoFiles(git.DefaultContext, repo, user2, &files_service.ChangeRepoFilesOptions{
370348
Files: []*files_service.ChangeRepoFile{
@@ -475,13 +453,6 @@ func TestPullRequestCommitStatusEvent(t *testing.T) {
475453
assert.NoError(t, err)
476454
assert.NotEmpty(t, repo)
477455

478-
// enable actions
479-
err = repo_service.UpdateRepositoryUnits(db.DefaultContext, repo, []repo_model.RepoUnit{{
480-
RepoID: repo.ID,
481-
Type: unit_model.TypeActions,
482-
}}, nil)
483-
assert.NoError(t, err)
484-
485456
// add user4 as the collaborator
486457
ctx := NewAPITestContext(t, repo.OwnerName, repo.Name, auth_model.AccessTokenScopeWriteRepository)
487458
t.Run("AddUser4AsCollaboratorWithReadAccess", doAPIAddCollaborator(ctx, "user4", perm.AccessModeRead))

0 commit comments

Comments
 (0)