mirror of
https://github.com/redmine/redmine.git
synced 2026-05-06 11:17:34 +02:00
Menu should not include "New issue" for users with copy issues permission only.
git-svn-id: http://svn.redmine.org/redmine/trunk@14290 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
@@ -671,4 +671,14 @@ class ProjectsControllerTest < ActionController::TestCase
|
||||
get :show, :id => 1
|
||||
assert_select '#main-menu a.new-issue', 0
|
||||
end
|
||||
|
||||
def test_project_menu_should_not_include_new_issue_link_for_users_with_copy_issues_permission_only
|
||||
role = Role.find(1)
|
||||
role.remove_permission! :add_issues
|
||||
role.add_permission! :copy_issues
|
||||
|
||||
@request.session[:user_id] = 2
|
||||
get :show, :id => 1
|
||||
assert_select '#main-menu a.new-issue', 0
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user