test(api): Add test for link rendering

Part-of: <https://dev.funkwhale.audio/funkwhale/funkwhale/-/merge_requests/2312>
This commit is contained in:
Ciarán Ainsworth 2022-12-29 17:35:09 +00:00
parent 101b1b6a23
commit 658b017c5e
1 changed files with 7 additions and 0 deletions

View File

@ -134,6 +134,13 @@ def test_join_url(start, end, expected):
True,
'<p class="foo">hello world</p>',
),
# Links should render with their href intact
(
"hello world\n[link](src)",
"text/markdown",
False,
'<p>hello world<br><a href="src">link</a></p>',
),
],
)
def test_render_html(text, content_type, permissive, expected):