diff options
-rw-r--r-- | lib/redmine/wiki_formatting/markdown/formatter.rb | 3 | ||||
-rw-r--r-- | test/unit/lib/redmine/wiki_formatting/markdown_formatter_test.rb | 9 |
2 files changed, 11 insertions, 1 deletions
diff --git a/lib/redmine/wiki_formatting/markdown/formatter.rb b/lib/redmine/wiki_formatting/markdown/formatter.rb index bfb04774c..2721adf3d 100644 --- a/lib/redmine/wiki_formatting/markdown/formatter.rb +++ b/lib/redmine/wiki_formatting/markdown/formatter.rb @@ -138,7 +138,8 @@ module Redmine :strikethrough => true, :superscript => true, :no_intra_emphasis => true, - :footnotes => true + :footnotes => true, + :lax_spacing => true ) end end diff --git a/test/unit/lib/redmine/wiki_formatting/markdown_formatter_test.rb b/test/unit/lib/redmine/wiki_formatting/markdown_formatter_test.rb index 77dd93c7d..5ad67f431 100644 --- a/test/unit/lib/redmine/wiki_formatting/markdown_formatter_test.rb +++ b/test/unit/lib/redmine/wiki_formatting/markdown_formatter_test.rb @@ -89,5 +89,14 @@ STR assert_equal '<p>This is a <a href="/issues">link</a></p>', @formatter.new(text).to_html.strip end + def test_markdown_should_not_require_surrounded_empty_line + text = <<-STR +This is a list: +* One +* Two +STR + assert_equal "<p>This is a list:</p>\n\n<ul>\n<li>One</li>\n<li>Two</li>\n</ul>", @formatter.new(text).to_html.strip + end + end end |