diff options
author | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2019-10-22 11:40:58 +0000 |
---|---|---|
committer | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2019-10-22 11:40:58 +0000 |
commit | 1961acdb87b98fc124725295af28795b11e218de (patch) | |
tree | e0cb9b32ca9b4107bb9e4c348b6dfc6b2742e8b9 /test/helpers | |
parent | 68ada471f4264dfbdfa285a2589eca6f07c37a6f (diff) | |
download | redmine-1961acdb87b98fc124725295af28795b11e218de.tar.gz redmine-1961acdb87b98fc124725295af28795b11e218de.zip |
code cleanup: rubocop: fix Layout/ClosingHeredocIndentation in ApplicationHelperTest#test_syntax_highlight
git-svn-id: http://svn.redmine.org/redmine/trunk@18808 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/helpers')
-rw-r--r-- | test/helpers/application_helper_test.rb | 20 |
1 files changed, 9 insertions, 11 deletions
diff --git a/test/helpers/application_helper_test.rb b/test/helpers/application_helper_test.rb index fe127ff7b..be1c60303 100644 --- a/test/helpers/application_helper_test.rb +++ b/test/helpers/application_helper_test.rb @@ -1148,17 +1148,15 @@ class ApplicationHelperTest < Redmine::HelperTest end def test_syntax_highlight - raw = <<-RAW -<pre><code class="ECMA_script"> -/* Hello */ -document.write("Hello World!"); -</code></pre> -RAW - - expected = <<-EXPECTED -<pre><code class="ECMA_script syntaxhl"><span class="cm">/* Hello */</span><span class="nb">document</span><span class="p">.</span><span class="nx">write</span><span class="p">(</span><span class="dl">"</span><span class="s2">Hello World!</span><span class="dl">"</span><span class="p">);</span></code></pre> -EXPECTED - + raw = <<~RAW + <pre><code class="ECMA_script"> + /* Hello */ + document.write("Hello World!"); + </code></pre> + RAW + expected = <<~EXPECTED + <pre><code class="ECMA_script syntaxhl"><span class="cm">/* Hello */</span><span class="nb">document</span><span class="p">.</span><span class="nx">write</span><span class="p">(</span><span class="dl">"</span><span class="s2">Hello World!</span><span class="dl">"</span><span class="p">);</span></code></pre> + EXPECTED assert_equal expected.gsub(%r{[\r\n\t]}, ''), textilizable(raw).gsub(%r{[\r\n\t]}, '') end |