blob: 42478dfeea2154b950acd106ad3c463ec7d80985 [file] [log] [blame]
import pytest
from markdown_it import MarkdownIt
@pytest.mark.parametrize(
"input,expected",
[
("#", "<h1></h1>\n"),
("###", "<h3></h3>\n"),
("` `", "<p><code> </code></p>\n"),
("``````", "<pre><code></code></pre>\n"),
("-", "<ul>\n<li></li>\n</ul>\n"),
("1.", "<ol>\n<li></li>\n</ol>\n"),
(">", "<blockquote></blockquote>\n"),
("---", "<hr />\n"),
("<h1></h1>", "<h1></h1>"),
("p", "<p>p</p>\n"),
("[reference]: /url", ""),
],
)
def test_no_end_newline(input, expected):
md = MarkdownIt()
text = md.render(input)
assert text == expected