Merged r1399, r1403, r1405 and r1406 from trunk.

git-svn-id: http://redmine.rubyforge.org/svn/branches/0.7-stable@1407 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang
2008-05-02 18:39:32 +00:00
parent 914d1e6645
commit 8bc721c264
9 changed files with 41 additions and 6 deletions

View File

@@ -63,6 +63,21 @@ class ProjectsControllerTest < Test::Unit::TestCase
assert_equal Project.find_by_identifier('ecookbook'), assigns(:project)
end
def test_private_subprojects_hidden
get :show, :id => 'ecookbook'
assert_response :success
assert_template 'show'
assert_no_tag :tag => 'a', :content => /Private child/
end
def test_private_subprojects_visible
@request.session[:user_id] = 2 # manager who is a member of the private subproject
get :show, :id => 'ecookbook'
assert_response :success
assert_template 'show'
assert_tag :tag => 'a', :content => /Private child/
end
def test_settings
@request.session[:user_id] = 2 # manager
get :settings, :id => 1