Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def test_render_html():
text = u"Hello, **world**!"
root = cmark.parse_document(text)
result = cmark.render_html(root)
assert result == '<p>Hello, <strong>world</strong>!</p>\n'
def test_parser_interface():
text = u"Hello, **world**!"
parser = cmark.parser_new()
cmark.parser_feed(parser, text)
root = cmark.parser_finish(parser)
result = cmark.render_html(root)
cmark.parser_free(parser)
assert result == '<p>Hello, <strong>world</strong>!</p>\n'