summaryrefslogtreecommitdiffstats
path: root/test/functional/roles_controller_test.rb
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2012-09-20 19:26:58 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2012-09-20 19:26:58 +0000
commit5328c4adcb6c34978652b5245b0de0b98903a6d1 (patch)
tree3c1cee447f5b2c34afc6aecb51980fad40ce258c /test/functional/roles_controller_test.rb
parent30b3e796ffe5ea5beb6fbf03d3f000e8968f89bb (diff)
downloadredmine-5328c4adcb6c34978652b5245b0de0b98903a6d1.tar.gz
redmine-5328c4adcb6c34978652b5245b0de0b98903a6d1.zip
Anonymous users should always see public issues only (#11872).
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@10437 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/functional/roles_controller_test.rb')
-rw-r--r--test/functional/roles_controller_test.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/functional/roles_controller_test.rb b/test/functional/roles_controller_test.rb
index 868c987a6..8aa74457a 100644
--- a/test/functional/roles_controller_test.rb
+++ b/test/functional/roles_controller_test.rb
@@ -110,6 +110,14 @@ class RolesControllerTest < ActionController::TestCase
assert_response :success
assert_template 'edit'
assert_equal Role.find(1), assigns(:role)
+ assert_select 'select[name=?]', 'role[issues_visibility]'
+ end
+
+ def test_edit_anonymous
+ get :edit, :id => Role.anonymous.id
+ assert_response :success
+ assert_template 'edit'
+ assert_select 'select[name=?]', 'role[issues_visibility]', 0
end
def test_edit_invalid_should_respond_with_404