Merge pull request #2576 from bhollis/maruku-update
This commit is contained in:
commit
ece22497dd
|
@ -45,7 +45,7 @@ Feature: Markdown
|
|||
When I run jekyll build
|
||||
Then the _site directory should exist
|
||||
And I should see "My awesome code" in "_site/index.html"
|
||||
And I should see "<pre><code>\nMy awesome code\n</code></pre>" in "_site/index.html"
|
||||
And I should see "<pre><code>My awesome code</code></pre>" in "_site/index.html"
|
||||
|
||||
Scenario: Maruku fenced codeblocks
|
||||
Given I have a configuration file with "markdown" set to "maruku"
|
||||
|
@ -64,4 +64,4 @@ Feature: Markdown
|
|||
When I run jekyll build
|
||||
Then the _site directory should exist
|
||||
And I should see "My awesome string" in "_site/index.html"
|
||||
And I should see "<pre class="ruby"><code class="ruby">\nputs "My awesome string"\n</code></pre>" in "_site/index.html"
|
||||
And I should see "<pre class="ruby"><code class="ruby">puts "My awesome string"</code></pre>" in "_site/index.html"
|
||||
|
|
|
@ -50,7 +50,7 @@ Gem::Specification.new do |s|
|
|||
s.add_development_dependency('rr', "~> 1.1")
|
||||
s.add_development_dependency('cucumber', "1.3.11")
|
||||
s.add_development_dependency('RedCloth', "~> 4.2")
|
||||
s.add_development_dependency('maruku', "0.7.0")
|
||||
s.add_development_dependency('maruku', "~> 0.7.0")
|
||||
s.add_development_dependency('rdiscount', "~> 1.6")
|
||||
s.add_development_dependency('launchy', "~> 2.3")
|
||||
s.add_development_dependency('simplecov', "~> 0.7")
|
||||
|
|
|
@ -75,13 +75,13 @@ CONTENT
|
|||
|
||||
tag = Jekyll::Tags::HighlightBlock.new('highlight', 'ruby linenos=table cssclass=hl', ["test", "{% endhighlight %}", "\n"])
|
||||
assert_equal({ :cssclass => 'hl', :linenos => 'table' }, tag.instance_variable_get(:@options))
|
||||
|
||||
|
||||
tag = Jekyll::Tags::HighlightBlock.new('highlight', 'ruby linenos=table cssclass=hl hl_linenos=3', ["test", "{% endhighlight %}", "\n"])
|
||||
assert_equal({ :cssclass => 'hl', :linenos => 'table', :hl_linenos => '3' }, tag.instance_variable_get(:@options))
|
||||
|
||||
|
||||
tag = Jekyll::Tags::HighlightBlock.new('highlight', 'ruby linenos=table cssclass=hl hl_linenos="3 5 6"', ["test", "{% endhighlight %}", "\n"])
|
||||
assert_equal({ :cssclass => 'hl', :linenos => 'table', :hl_linenos => ['3', '5', '6'] }, tag.instance_variable_get(:@options))
|
||||
|
||||
|
||||
tag = Jekyll::Tags::HighlightBlock.new('highlight', 'Ruby ', ["test", "{% endhighlight %}", "\n"])
|
||||
assert_equal "ruby", tag.instance_variable_get(:@lang), "lexers should be case insensitive"
|
||||
end
|
||||
|
@ -420,9 +420,8 @@ CONTENT
|
|||
)
|
||||
end
|
||||
|
||||
# todo: if #112 is merged into maruku, update to remove the newlines inside code block
|
||||
should "render fenced code blocks" do
|
||||
assert_match %r{<pre class=\"ruby\"><code class=\"ruby\">\nputs "Hello world"\n</code></pre>}, @result.strip
|
||||
assert_match %r{<pre class=\"ruby\"><code class=\"ruby\">puts "Hello world"</code></pre>}, @result.strip
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue