From 70448a0797202f91778c35ecd6adf4b36c95897d Mon Sep 17 00:00:00 2001 From: vmishenev Date: Mon, 30 Aug 2021 17:40:02 +0300 Subject: Escape text for GFM --- .../gfm/src/test/kotlin/renderers/gfm/SimpleElementsTest.kt | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'plugins/gfm/src/test/kotlin/renderers') diff --git a/plugins/gfm/src/test/kotlin/renderers/gfm/SimpleElementsTest.kt b/plugins/gfm/src/test/kotlin/renderers/gfm/SimpleElementsTest.kt index ee156c7f..b4af12b2 100644 --- a/plugins/gfm/src/test/kotlin/renderers/gfm/SimpleElementsTest.kt +++ b/plugins/gfm/src/test/kotlin/renderers/gfm/SimpleElementsTest.kt @@ -204,4 +204,17 @@ class SimpleElementsTest : GfmRenderingOnlyTestBase() { assertEquals(expect, renderedContent) } + @Test + fun escapeText() { + val page = testPage { + text( + "a", + ) + } + val expect = + "//[testPage](test-page.md)\n\n<b>a</b>" + CommonmarkRenderer(context).render(page) + assertEquals(expect, renderedContent) + } + } -- cgit