]> source.dussan.org Git - redmine.git/commitdiff
shorten long line of ApplicationHelperTest
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Mon, 30 Nov 2020 15:49:06 +0000 (15:49 +0000)
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Mon, 30 Nov 2020 15:49:06 +0000 (15:49 +0000)
git-svn-id: http://svn.redmine.org/redmine/trunk@20526 e93f8b46-1217-0410-a6f0-8f06a7374b81

test/helpers/application_helper_test.rb

index ec196771ee8ab5f3f0ddc7268c58a48acedb1f11..42af59566da6384a08f93730934b83ed6fb22d27 100644 (file)
@@ -1523,18 +1523,30 @@ class ApplicationHelperTest < Redmine::HelperTest
       ).delete("\n")
     # heading that contains inline code
     assert_match(
-      Regexp.new('<div class="contextual heading-2" title="Edit this section" id="section-4">' +
-      '<a class="icon-only icon-edit" href="/projects/1/wiki/Test/edit\?section=4">Edit this section</a></div>' +
-      '<a name="Subtitle-with-inline-code"></a>' +
-      '<h2 >Subtitle with <code>inline code</code><a href="#Subtitle-with-inline-code" class="wiki-anchor">&para;</a></h2>'),
-      result)
+      Regexp.new(
+        '<div class="contextual heading-2" title="Edit this section" id="section-4">' \
+        '<a class="icon-only icon-edit" href="/projects/1/wiki/Test/edit\?section=4">' \
+        'Edit this section' \
+        '</a></div>' \
+        '<a name="Subtitle-with-inline-code"></a>' \
+        '<h2 >Subtitle with ' \
+        '<code>inline code</code><a href="#Subtitle-with-inline-code" class="wiki-anchor">&para;</a>' \
+        '</h2>'
+      ),
+      result
+    )
     # last heading
     assert_match(
-      Regexp.new('<div class="contextual heading-2" title="Edit this section" id="section-5">' +
-      '<a class="icon-only icon-edit" href="/projects/1/wiki/Test/edit\?section=5">Edit this section</a></div>' +
-      '<a name="Subtitle-after-pre-tag"></a>' +
-      '<h2 >Subtitle after pre tag<a href="#Subtitle-after-pre-tag" class="wiki-anchor">&para;</a></h2>'),
-      result)
+      Regexp.new(
+        '<div class="contextual heading-2" title="Edit this section" id="section-5">' \
+        '<a class="icon-only icon-edit" href="/projects/1/wiki/Test/edit\?section=5">' \
+        'Edit this section' \
+        '</a></div>' \
+        '<a name="Subtitle-after-pre-tag"></a>' \
+        '<h2 >Subtitle after pre tag<a href="#Subtitle-after-pre-tag" class="wiki-anchor">&para;</a></h2>'
+      ),
+      result
+    )
   end
 
   def test_default_formatter