diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2015-02-08 10:20:53 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2015-02-08 10:20:53 +0000 |
commit | 01f673be08be68247b72a8954379b3f0c7a9a9d3 (patch) | |
tree | 866383ef7f9e0e2b9fe73aee4f6dea417602d692 /test | |
parent | 92cdae49199e6e8cc26408d0bbeea1466e7189c6 (diff) | |
download | redmine-01f673be08be68247b72a8954379b3f0c7a9a9d3.tar.gz redmine-01f673be08be68247b72a8954379b3f0c7a9a9d3.zip |
Removed :move_issues permission (#18855).
This permission was wrongly used to allow bulk issue copy. To prevent user from moving an issue to another project, the project field should now be set to read-only in the workflow permissions. A migration does this automatically for roles that have the edit_issues permission without having the move_issues permission.
git-svn-id: http://svn.redmine.org/redmine/trunk@13981 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test')
-rw-r--r-- | test/fixtures/roles.yml | 3 | ||||
-rw-r--r-- | test/unit/issue_test.rb | 8 |
2 files changed, 4 insertions, 7 deletions
diff --git a/test/fixtures/roles.yml b/test/fixtures/roles.yml index 241c5afe6..000173bbe 100644 --- a/test/fixtures/roles.yml +++ b/test/fixtures/roles.yml @@ -20,7 +20,6 @@ roles_001: - :manage_issue_relations - :manage_subtasks - :add_issue_notes - - :move_issues - :delete_issues - :view_issue_watchers - :add_issue_watchers @@ -81,7 +80,6 @@ roles_002: - :manage_issue_relations - :manage_subtasks - :add_issue_notes - - :move_issues - :delete_issues - :view_issue_watchers - :save_queries @@ -128,7 +126,6 @@ roles_003: - :edit_issues - :manage_issue_relations - :add_issue_notes - - :move_issues - :view_issue_watchers - :save_queries - :view_gantt diff --git a/test/unit/issue_test.rb b/test/unit/issue_test.rb index 0384dfb0e..768899856 100644 --- a/test/unit/issue_test.rb +++ b/test/unit/issue_test.rb @@ -1211,13 +1211,13 @@ class IssueTest < ActiveSupport::TestCase assert issue.save end - def test_allowed_target_projects_on_move_should_include_projects_with_issue_tracking_enabled - assert_include Project.find(2), Issue.allowed_target_projects_on_move(User.find(2)) + def test_allowed_target_projects_should_include_projects_with_issue_tracking_enabled + assert_include Project.find(2), Issue.allowed_target_projects(User.find(2)) end - def test_allowed_target_projects_on_move_should_not_include_projects_with_issue_tracking_disabled + def test_allowed_target_projects_should_not_include_projects_with_issue_tracking_disabled Project.find(2).disable_module! :issue_tracking - assert_not_include Project.find(2), Issue.allowed_target_projects_on_move(User.find(2)) + assert_not_include Project.find(2), Issue.allowed_target_projects(User.find(2)) end def test_move_to_another_project_with_same_category |