diff options
author | Lunny Xiao <xiaolunwen@gmail.com> | 2022-03-29 22:57:33 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-29 16:57:33 +0200 |
commit | 74731c3a5aea71c81e4ca75bde96154f3adf3cfa (patch) | |
tree | 64b01935ab9912de71318eac447721e41b200135 /models/issue_assignees_test.go | |
parent | bd97736b9c7a16023bc9abf17be6157284f655b1 (diff) | |
download | gitea-74731c3a5aea71c81e4ca75bde96154f3adf3cfa.tar.gz gitea-74731c3a5aea71c81e4ca75bde96154f3adf3cfa.zip |
Move some issue methods as functions (#19255)
* Move some issue methods as functions
* Fix bug
Diffstat (limited to 'models/issue_assignees_test.go')
-rw-r--r-- | models/issue_assignees_test.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/models/issue_assignees_test.go b/models/issue_assignees_test.go index dd9a42b572..41a3ad86e3 100644 --- a/models/issue_assignees_test.go +++ b/models/issue_assignees_test.go @@ -23,17 +23,17 @@ func TestUpdateAssignee(t *testing.T) { // Assign multiple users user2, err := user_model.GetUserByID(2) assert.NoError(t, err) - _, _, err = issue.ToggleAssignee(&user_model.User{ID: 1}, user2.ID) + _, _, err = ToggleIssueAssignee(issue, &user_model.User{ID: 1}, user2.ID) assert.NoError(t, err) user3, err := user_model.GetUserByID(3) assert.NoError(t, err) - _, _, err = issue.ToggleAssignee(&user_model.User{ID: 1}, user3.ID) + _, _, err = ToggleIssueAssignee(issue, &user_model.User{ID: 1}, user3.ID) assert.NoError(t, err) user1, err := user_model.GetUserByID(1) // This user is already assigned (see the definition in fixtures), so running UpdateAssignee should unassign him assert.NoError(t, err) - _, _, err = issue.ToggleAssignee(&user_model.User{ID: 1}, user1.ID) + _, _, err = ToggleIssueAssignee(issue, &user_model.User{ID: 1}, user1.ID) assert.NoError(t, err) // Check if he got removed |