Sha256: ca38bd7bf9771a01eb7298c56ffc454e4db588c1c794dacaa386f59d816bec2b

Contents?: true

Size: 374 Bytes

Versions: 38

Compression:

Stored size: 374 Bytes

Contents

require 'test_helper'

class TestLinebreaks < Minitest::Test
  def test_hardbreak_no_spaces
    doc = CommonMarker.render_doc("foo\nbaz")
    assert_equal "<p>foo<br />\nbaz</p>\n", doc.to_html(:HARDBREAKS)
  end

  def test_hardbreak_with_spaces
    doc = CommonMarker.render_doc("foo  \nbaz")
    assert_equal "<p>foo<br />\nbaz</p>\n", doc.to_html(:HARDBREAKS)
  end
end

Version data entries

38 entries across 38 versions & 2 rubygems

Version Path
commonmarker-0.18.2 test/test_linebreaks.rb
commonmarker-0.18.1 test/test_linebreaks.rb
commonmarker-0.18.0 test/test_linebreaks.rb
commonmarker-0.17.13 test/test_linebreaks.rb
commonmarker-0.17.12 test/test_linebreaks.rb
commonmarker-0.17.11 test/test_linebreaks.rb
commonmarker-0.17.10 test/test_linebreaks.rb
tdiary-5.0.8 vendor/bundle/gems/commonmarker-0.17.9/test/test_linebreaks.rb
commonmarker-0.17.9 test/test_linebreaks.rb
commonmarker-0.17.8 test/test_linebreaks.rb
commonmarker-0.17.7.1 test/test_linebreaks.rb
commonmarker-0.17.7 test/test_linebreaks.rb
commonmarker-0.17.6 test/test_linebreaks.rb
commonmarker-0.17.5 test/test_linebreaks.rb
commonmarker-0.17.4 test/test_linebreaks.rb
commonmarker-0.17.2 test/test_linebreaks.rb
commonmarker-0.17.1 test/test_linebreaks.rb
commonmarker-0.17.0 test/test_linebreaks.rb
commonmarker-0.16.8 test/test_linebreaks.rb
commonmarker-0.16.7 test/test_linebreaks.rb