aboutsummaryrefslogtreecommitdiffstats
path: root/models/issue_user_test.go
diff options
context:
space:
mode:
authorkolaente <konrad@kola-entertainments.de>2018-05-09 18:29:04 +0200
committerLauris BH <lauris@nix.lv>2018-05-09 19:29:04 +0300
commit95f2e2b57beedcdeb2b9623dc86e26f252fdd7bd (patch)
treeebfeb5b898f72fc57ac1fe9680374fdb4bc91aeb /models/issue_user_test.go
parent238a997ec0b5d3e3bed0e55edcacebb44f86d373 (diff)
downloadgitea-95f2e2b57beedcdeb2b9623dc86e26f252fdd7bd.tar.gz
gitea-95f2e2b57beedcdeb2b9623dc86e26f252fdd7bd.zip
Multiple assignees (#3705)
Diffstat (limited to 'models/issue_user_test.go')
-rw-r--r--models/issue_user_test.go17
1 files changed, 0 insertions, 17 deletions
diff --git a/models/issue_user_test.go b/models/issue_user_test.go
index e3ebfa8fa2..a333bc8619 100644
--- a/models/issue_user_test.go
+++ b/models/issue_user_test.go
@@ -32,23 +32,6 @@ func Test_newIssueUsers(t *testing.T) {
AssertExistsAndLoadBean(t, &IssueUser{IssueID: newIssue.ID, UID: repo.OwnerID})
}
-func TestUpdateIssueUserByAssignee(t *testing.T) {
- assert.NoError(t, PrepareTestDatabase())
- issue := AssertExistsAndLoadBean(t, &Issue{ID: 1}).(*Issue)
-
- // artificially change assignee in issue_user table
- AssertSuccessfulInsert(t, &IssueUser{IssueID: issue.ID, UID: 5, IsAssigned: true})
- _, err := x.Cols("is_assigned").
- Update(&IssueUser{IsAssigned: false}, &IssueUser{IssueID: issue.ID, UID: issue.AssigneeID})
- assert.NoError(t, err)
-
- assert.NoError(t, UpdateIssueUserByAssignee(issue))
-
- // issue_user table should now be correct again
- AssertExistsAndLoadBean(t, &IssueUser{IssueID: issue.ID, UID: issue.AssigneeID}, "is_assigned=1")
- AssertExistsAndLoadBean(t, &IssueUser{IssueID: issue.ID, UID: 5}, "is_assigned=0")
-}
-
func TestUpdateIssueUserByRead(t *testing.T) {
assert.NoError(t, PrepareTestDatabase())
issue := AssertExistsAndLoadBean(t, &Issue{ID: 1}).(*Issue)