Skip to content
Snippets Groups Projects
Commit 114956af authored by Robin Stocker's avatar Robin Stocker
Browse files

Fix thematic break and list items

parent 5a0960f9
Branches
Tags
No related merge requests found
......@@ -89,7 +89,8 @@ public class CoreMarkdownNodeRenderer extends AbstractVisitor implements NodeRen
@Override
public void visit(ThematicBreak thematicBreak) {
writer.raw("***");
// Let's use ___ as it doesn't introduce ambiguity with * or - list item markers
writer.raw("___");
writer.block();
}
......
......@@ -12,10 +12,11 @@ public class MarkdownRendererTest {
@Test
public void testThematicBreaks() {
assertRoundTrip("***\n");
// TODO: spec: If you want a thematic break in a list item, use a different bullet:
assertRoundTrip("***\n\nfoo\n");
assertRoundTrip("___\n");
assertRoundTrip("___\n\nfoo\n");
// List item with hr -> hr needs to not use the same as the marker
assertRoundTrip("* ___\n");
assertRoundTrip("- ___\n");
}
@Test
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment