From 85da4abc206f2cc8819836bb0e8727de3a51d24c Mon Sep 17 00:00:00 2001 From: Christoph Schlosser Date: Fri, 10 Oct 2025 17:19:27 +0200 Subject: g2h: Render markdown files instead of putting them into code blocks --- tests/file_page_test.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'tests') diff --git a/tests/file_page_test.py b/tests/file_page_test.py index daa9b6c..5c380b8 100644 --- a/tests/file_page_test.py +++ b/tests/file_page_test.py @@ -94,3 +94,15 @@ def test_backticks_in_text_content(): file.data_stream.read.return_value = '```'.encode() context = page.context() assert(context['backtick_max'] == 4) + +def test_markdown(): + file = MagicMock() + tree = MagicMock() + commit = MagicMock() + commit.hexsha = '123' + commit.tree = tree + commit.tree.join.return_value = file + page = FilePage('test/file', 'file test', commit, 'file.Md', '', 'file/content') + file.data_stream.read.return_value = '```'.encode() + context = page.context() + assert(context['backtick_max'] == 0) -- cgit v1.2.3