Using a regexp to determine if a tag is a heading.

This commit is contained in:
Igor Dvorkin
2020-12-11 16:54:14 -08:00
parent d558617cd7
commit 7780f82c30
2 changed files with 10 additions and 1 deletions

View File

@@ -115,6 +115,14 @@ def test_hn_nested_tag():
assert md('<h3>A <blockquote>BQ</blockquote> C </h3>') == '### A BQ C\n\n'
def test_hr():
assert md('<hr>hr</hr>') == 'hr'
def test_head():
assert md('<head>head</head>') == 'head'
def test_atx_headings():
assert md('<h1>Hello</h1>', heading_style=ATX) == '# Hello\n\n'
assert md('<h2>Hello</h2>', heading_style=ATX) == '## Hello\n\n'