mirror of
https://github.com/meineerde/redmine.git
synced 2025-12-19 15:01:14 +00:00
Merged r4241 from trunk.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/branches/1.0-stable@4316 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
e29696ea37
commit
05432cfc3d
@ -367,7 +367,7 @@ class Issue < ActiveRecord::Base
|
|||||||
def assignable_users
|
def assignable_users
|
||||||
users = project.assignable_users
|
users = project.assignable_users
|
||||||
users << author if author
|
users << author if author
|
||||||
users.sort
|
users.uniq.sort
|
||||||
end
|
end
|
||||||
|
|
||||||
# Versions that the issue can be assigned to
|
# Versions that the issue can be assigned to
|
||||||
|
|||||||
@ -523,6 +523,15 @@ class IssueTest < ActiveSupport::TestCase
|
|||||||
|
|
||||||
assert issue.assignable_users.include?(non_project_member)
|
assert issue.assignable_users.include?(non_project_member)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
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
|
||||||
|
|
||||||
|
assignable_user_ids.each do |user_id|
|
||||||
|
assert_equal 1, assignable_user_ids.count(user_id), "User #{user_id} appears more or less than once"
|
||||||
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_create_should_send_email_notification
|
def test_create_should_send_email_notification
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user