Rails4: replace deprecated find_all_by_* at IssueTest

git-svn-id: http://svn.redmine.org/redmine/trunk@12495 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Toshi MARUYAMA 2014-01-07 15:42:49 +00:00
parent 1d0c93792b
commit 8dc4992973
1 changed files with 2 additions and 2 deletions

View File

@ -564,8 +564,8 @@ class IssueTest < ActiveSupport::TestCase
issue = Issue.find(1)
assert !admin.member_of?(issue.project)
expected_statuses = [issue.status] +
WorkflowTransition.find_all_by_old_status_id(
issue.status_id).map(&:new_status).uniq.sort
WorkflowTransition.where(:old_status_id => issue.status_id).
all.map(&:new_status).uniq.sort
assert_equal expected_statuses, issue.new_statuses_allowed_to(admin)
end