]> source.dussan.org Git - redmine.git/commitdiff
Merged r10083 from trunk to 2.0-stable (#11511)
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Fri, 27 Jul 2012 00:40:57 +0000 (00:40 +0000)
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Fri, 27 Jul 2012 00:40:57 +0000 (00:40 +0000)
fix confirmation page has broken HTML when a project folding sub project is deleted.

Contributed by Haruka Yoshihara.

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/branches/2.0-stable@10084 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/views/projects/destroy.html.erb
test/functional/projects_controller_test.rb

index d4348b040d3e15d75e95c97a17f53cfdee29d2de..6bed5212ae0cee1a7e16da78c436617c01033f9d 100644 (file)
@@ -4,7 +4,8 @@
 <%=l(:text_project_destroy_confirmation)%>
 
 <% if @project_to_destroy.descendants.any? %>
-<br /><%= l(:text_subprojects_destroy_warning, content_tag('strong', h(@project_to_destroy.descendants.collect{|p| p.to_s}.join(', ')))) %>
+<br /><%= l(:text_subprojects_destroy_warning,
+          content_tag('strong', h(@project_to_destroy.descendants.collect{|p| p.to_s}.join(', ')))).html_safe %>
 <% end %>
 </p>
 <p>
index 299a6e76716bcf4c4ff994853a6f5d4f30d5b1dd..fa916b6212ffc7cb7e8f87f1c6ba30aa324b3360 100644 (file)
@@ -412,6 +412,10 @@ class ProjectsControllerTest < ActionController::TestCase
     assert_response :success
     assert_template 'destroy'
     assert_not_nil Project.find_by_id(1)
+    assert_tag :tag => 'strong',
+               :content => ['Private child of eCookbook',
+                            'Child of private child, eCookbook Subproject 1',
+                            'eCookbook Subproject 2'].join(', ')
   end
 
   def test_destroy