diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2010-10-23 09:48:01 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2010-10-23 09:48:01 +0000 |
commit | eea456ed84d159289bdc8826439923d365816fa8 (patch) | |
tree | 48e20079f38b0d3998df72b4a6bb4dde373da9a2 /test/functional/projects_controller_test.rb | |
parent | 1e4776fa644525168d0e3bfc0e4232f9dc43d42c (diff) | |
download | redmine-eea456ed84d159289bdc8826439923d365816fa8.tar.gz redmine-eea456ed84d159289bdc8826439923d365816fa8.zip |
Improved error message when trying to access an archived project (#2995).
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@4285 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/functional/projects_controller_test.rb')
-rw-r--r-- | test/functional/projects_controller_test.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/functional/projects_controller_test.rb b/test/functional/projects_controller_test.rb index 8a9bbe6d5..7122f89e2 100644 --- a/test/functional/projects_controller_test.rb +++ b/test/functional/projects_controller_test.rb @@ -296,6 +296,16 @@ class ProjectsControllerTest < ActionController::TestCase assert_equal Project.find_by_identifier('ecookbook'), assigns(:project) end + def show_archived_project_should_be_denied + project = Project.find_by_identifier('ecookbook') + project.archive! + + get :show, :id => 'ecookbook' + assert_response 403 + assert_nil assigns(:project) + assert_tag :tag => 'p', :content => /archived/ + end + def test_private_subprojects_hidden get :show, :id => 'ecookbook' assert_response :success |