import org.junit.Before; import org.junit.Ignore; import org.junit.Test; import static org.junit.Assert.assertEquals; public class MarkdownTest { private Markdown markdown; @Before public void setup() { markdown = new Markdown(); } @Test public void normalTextAsAParagraph() { String input = "This will be a paragraph"; String expected = "
This will be a paragraph
"; assertEquals(expected, markdown.parse(input)); } @Ignore("Remove to run test") @Test public void italics() { String input = "_This will be italic_"; String expected = "This will be italic
"; assertEquals(expected, markdown.parse(input)); } @Ignore("Remove to run test") @Test public void boldText() { String input = "__This will be bold__"; String expected = "This will be bold
"; assertEquals(expected, markdown.parse(input)); } @Ignore("Remove to run test") @Test public void normalItalicsAndBoldText() { String input = "This will _be_ __mixed__"; String expected = "This will be mixed
"; assertEquals(expected, markdown.parse(input)); } @Ignore("Remove to run test") @Test public void withH1HeaderLevel() { String input = "# This will be an h1"; String expected = "