Project

General

Profile

Patch #35104 » 0002-application_helper_test.patch

Martin Cizek, 2021-04-15 22:00

View differences:

test/helpers/application_helper_test.rb
1326 1326
      </code></pre>
1327 1327
    RAW
1328 1328
    expected = <<~EXPECTED
1329
      <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>
1329
      <pre><code class="ECMA_script syntaxhl" data-language=\"ECMA_script\"><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>
1330 1330
    EXPECTED
1331 1331
    assert_equal expected.gsub(%r{[\r\n\t]}, ''), textilizable(raw).gsub(%r{[\r\n\t]}, '')
1332 1332
  end
......
1338 1338
      </code></pre>
1339 1339
    RAW
1340 1340
    expected = <<~EXPECTED
1341
      <pre><code class=\"ruby syntaxhl\"><span class=\"n\">x</span> <span class=\"o\">=</span> <span class=\"n\">a</span> <span class=\"o\">&amp;</span> <span class=\"n\">b</span></code></pre>
1341
      <pre><code class=\"ruby syntaxhl\" data-language=\"ruby\"><span class=\"n\">x</span> <span class=\"o\">=</span> <span class=\"n\">a</span> <span class=\"o\">&amp;</span> <span class=\"n\">b</span></code></pre>
1342 1342
    EXPECTED
1343 1343
    with_settings :text_formatting => 'textile' do
1344 1344
      assert_equal expected.gsub(%r{[\r\n\t]}, ''), textilizable(raw).gsub(%r{[\r\n\t]}, '')
(2-2/2)