import unittest from markdown import parse_markdown # Tests adapted from `problem-specifications//canonical-data.json` @ v1.0.0 class TestMarkdown(unittest.TestCase): def test_paragraph(self): self.assertEqual(parse_markdown('This will be a paragraph'), '
This will be a paragraph
') def test_italics(self): self.assertEqual(parse_markdown('_This will be italic_'), 'This will be italic
') def test_bold(self): self.assertEqual(parse_markdown('__This will be bold__'), 'This will be bold
') def test_mixed(self): self.assertEqual(parse_markdown('This will _be_ __mixed__'), 'This will be mixed
') def test_h1(self): self.assertEqual(parse_markdown('# This will be an h1'), 'Item 1
Item 2