aboutsummaryrefslogtreecommitdiffstats
path: root/tests/heading_atx.rs
diff options
context:
space:
mode:
authorLibravatar Titus Wormer <tituswormer@gmail.com>2022-08-01 13:06:18 +0200
committerLibravatar Titus Wormer <tituswormer@gmail.com>2022-08-01 13:06:18 +0200
commit13cf914b5162fb12c842e983538b42d4b60cdcb8 (patch)
tree41edfd9709791567f315292ec6c3d1e687c02269 /tests/heading_atx.rs
parent1bb160f9dc45c3cdbe929e8965be69bcf8415d0c (diff)
downloadmarkdown-rs-13cf914b5162fb12c842e983538b42d4b60cdcb8.tar.gz
markdown-rs-13cf914b5162fb12c842e983538b42d4b60cdcb8.tar.bz2
markdown-rs-13cf914b5162fb12c842e983538b42d4b60cdcb8.zip
Fix bug on empty heading (atx)
Diffstat (limited to '')
-rw-r--r--tests/heading_atx.rs8
1 files changed, 7 insertions, 1 deletions
diff --git a/tests/heading_atx.rs b/tests/heading_atx.rs
index 22c9f82..f785ca6 100644
--- a/tests/heading_atx.rs
+++ b/tests/heading_atx.rs
@@ -179,7 +179,13 @@ fn heading_atx() {
assert_eq!(
micromark("## \n#\n### ###"),
"<h2></h2>\n<h1></h1>\n<h3></h3>",
- "should support empty atx headings"
+ "should support empty atx headings (1)"
+ );
+
+ assert_eq!(
+ micromark("#\na\n# b"),
+ "<h1></h1>\n<p>a</p>\n<h1>b</h1>",
+ "should support empty atx headings (2)"
);
assert_eq!(