Sha256: befd565a99f21a68babcac80facf862f5b6f1f1f07974626328df6338b147eb1

Contents?: true

Size: 403 Bytes

Versions: 4

Compression:

Stored size: 403 Bytes

Contents

# frozen_string_literal: true

require 'test_helper'

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

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

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
qiita_marker-0.23.2.3 test/test_linebreaks.rb
qiita_marker-0.23.2.2 test/test_linebreaks.rb
qiita_marker-0.23.2.1 test/test_linebreaks.rb
qiita_marker-0.23.2.0 test/test_linebreaks.rb