Skip to content

Commit

Permalink
fix heredoc indentation
Browse files Browse the repository at this point in the history
  • Loading branch information
korny committed Nov 24, 2019
1 parent 1b140ba commit 1e66d13
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
8 changes: 4 additions & 4 deletions test/functional/basic.rb
Expand Up @@ -97,15 +97,15 @@ def test_comment_filter
code
more code
EXPECTED
EXPECTED
#!/usr/bin/env ruby
=begin
A multi-line comment.
=end
code
# A single-line comment.
more code # and another comment, in-line.
INPUT
INPUT
end

def test_lines_of_code
Expand All @@ -117,7 +117,7 @@ def test_lines_of_code
code
# A single-line comment.
more code # and another comment, in-line.
INPUT
INPUT
rHTML = <<-RHTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
Expand All @@ -138,7 +138,7 @@ def test_lines_of_code
</body>
</html>
RHTML
RHTML
assert_equal 0, CodeRay.scan(rHTML, :html).lines_of_code
assert_equal 0, CodeRay.scan(rHTML, :php).lines_of_code
assert_equal 0, CodeRay.scan(rHTML, :yaml).lines_of_code
Expand Down
8 changes: 4 additions & 4 deletions test/functional/for_redcloth.rb
Expand Up @@ -22,7 +22,7 @@ def test_for_redcloth
<div lang="ruby" class="CodeRay">
<div class="code"><pre>puts <span style="background-color:hsla(0,100%,50%,0.05)"><span style="color:#710">&quot;</span><span style="color:#D20">Hello, World!</span><span style="color:#710">&quot;</span></span></pre></div>
</div>
BLOCKCODE
BLOCKCODE
RedCloth.new('bc[ruby]. puts "Hello, World!"').to_html
end

Expand All @@ -32,15 +32,15 @@ def test_for_redcloth_no_lang
RedCloth.new('@puts "Hello, World!"@').to_html
assert_equal <<-BLOCKCODE.chomp,
<pre><code>puts \"Hello, World!\"</code></pre>
BLOCKCODE
BLOCKCODE
RedCloth.new('bc. puts "Hello, World!"').to_html
end

def test_for_redcloth_style
require 'coderay/for_redcloth'
assert_equal <<-BLOCKCODE.chomp,
<pre style=\"color: red;\"><code style=\"color: red;\">puts \"Hello, World!\"</code></pre>
BLOCKCODE
BLOCKCODE
RedCloth.new('bc{color: red}. puts "Hello, World!"').to_html
end

Expand All @@ -52,7 +52,7 @@ def test_for_redcloth_escapes
<div lang="ruby" class="CodeRay">
<div class="code"><pre>&amp;</pre></div>
</div>
BLOCKCODE
BLOCKCODE
RedCloth.new('bc[ruby]. &').to_html
end

Expand Down
2 changes: 1 addition & 1 deletion test/unit/comment_filter.rb
Expand Up @@ -47,7 +47,7 @@ def mymethod(self):
def myfunction():
PYTHON_FILTERED
PYTHON_FILTERED
end

end

0 comments on commit 1e66d13

Please sign in to comment.