diff options
author | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2019-11-08 06:26:54 +0000 |
---|---|---|
committer | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2019-11-08 06:26:54 +0000 |
commit | 2efe9dc61097177a15e5953516847f61aab1d1ad (patch) | |
tree | 890c0206ed18866348c29a344cda74009471868a /test/functional/wiki_controller_test.rb | |
parent | 4810d5f5c4d2ba3899180c697990895a9660c759 (diff) | |
download | redmine-2efe9dc61097177a15e5953516847f61aab1d1ad.tar.gz redmine-2efe9dc61097177a15e5953516847f61aab1d1ad.zip |
cleanup: rubocop: fix Layout/AlignArguments in test/functional/wiki_controller_test.rb
git-svn-id: http://svn.redmine.org/redmine/trunk@18949 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/functional/wiki_controller_test.rb')
-rw-r--r-- | test/functional/wiki_controller_test.rb | 20 |
1 files changed, 9 insertions, 11 deletions
diff --git a/test/functional/wiki_controller_test.rb b/test/functional/wiki_controller_test.rb index 7d36ea3f2..e3ac6cb4e 100644 --- a/test/functional/wiki_controller_test.rb +++ b/test/functional/wiki_controller_test.rb @@ -36,7 +36,7 @@ class WikiControllerTest < Redmine::ControllerTest assert_select 'h1', :text => /CookBook documentation/ # child_pages macro assert_select 'ul.pages-hierarchy>li>a[href=?]', '/projects/ecookbook/wiki/Page_with_an_inline_image', - :text => 'Page with an inline image' + :text => 'Page with an inline image' end def test_export_link @@ -314,11 +314,9 @@ class WikiControllerTest < Redmine::ControllerTest def test_edit_page @request.session[:user_id] = 2 get :edit, :params => {:project_id => 'ecookbook', :id => 'Another_page'} - assert_response :success - assert_select 'textarea[name=?]', 'content[text]', - :text => WikiPage.find_by_title('Another_page').content.text + :text => WikiPage.find_by_title('Another_page').content.text end def test_edit_section @@ -1088,7 +1086,7 @@ class WikiControllerTest < Redmine::ControllerTest assert_equal 'application/pdf', @response.content_type assert_equal 'attachment; filename="CookBook_documentation.pdf"', - @response.headers['Content-Disposition'] + @response.headers['Content-Disposition'] end def test_show_html @@ -1098,7 +1096,7 @@ class WikiControllerTest < Redmine::ControllerTest assert_equal 'text/html', @response.content_type assert_equal 'attachment; filename="CookBook_documentation.html"', - @response.headers['Content-Disposition'] + @response.headers['Content-Disposition'] assert_select 'h1', :text => /CookBook documentation/ end @@ -1109,7 +1107,7 @@ class WikiControllerTest < Redmine::ControllerTest assert_equal 'text/html', @response.content_type assert_equal 'attachment; filename="CookBook_documentation.html"', - @response.headers['Content-Disposition'] + @response.headers['Content-Disposition'] assert_select 'h1', :text => /CookBook documentation v2/ end @@ -1120,7 +1118,7 @@ class WikiControllerTest < Redmine::ControllerTest assert_equal 'text/plain', @response.content_type assert_equal 'attachment; filename="CookBook_documentation.txt"', - @response.headers['Content-Disposition'] + @response.headers['Content-Disposition'] assert_include 'h1. CookBook documentation', @response.body end @@ -1131,7 +1129,7 @@ class WikiControllerTest < Redmine::ControllerTest assert_equal 'text/plain', @response.content_type assert_equal 'attachment; filename="CookBook_documentation.txt"', - @response.headers['Content-Disposition'] + @response.headers['Content-Disposition'] assert_include 'h1. CookBook documentation v2', @response.body end @@ -1144,14 +1142,14 @@ class WikiControllerTest < Redmine::ControllerTest get :show, :params => {:project_id => 1, :id => title, :format => format} assert_response :success assert_equal "attachment; filename=\"#{title}.#{format}\"", - @response.headers['Content-Disposition'] + @response.headers['Content-Disposition'] # Microsoft's browsers: filename should be URI encoded @request.user_agent = 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/52.0.2743.116 Safari/537.36 Edge/15.15063' get :show, :params => {:project_id => 1, :id => title, :format => format} assert_response :success filename = URI.encode("#{title}.#{format}") assert_equal "attachment; filename=\"#{filename}\"", - @response.headers['Content-Disposition'] + @response.headers['Content-Disposition'] end end |