Commit 7e4292cc authored by jplang's avatar jplang
Browse files

Assignee is removed on issue update if assignee account is locked (#8884).

git-svn-id: e93f8b46-1217-0410-a6f0-8f06a7374b81
parent 39e00b75
......@@ -451,6 +451,7 @@ class Issue < ActiveRecord::Base
def assignable_users
users = project.assignable_users
users << author if author
users << assigned_to if assigned_to
......@@ -693,6 +693,15 @@ class IssueTest < ActiveSupport::TestCase
assert issue.assignable_users.include?(non_project_member)
should "include the current assignee" do
project = Project.find(1)
user = User.generate!
issue = Issue.generate_for_project!(project, :assigned_to => user)
assert Issue.find(
should "not show the issue author twice" do
assignable_user_ids = Issue.find(1).assignable_users.collect(&:id)
assert_equal 2, assignable_user_ids.length
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment