summaryrefslogtreecommitdiff
path: root/tests/test_syntax/extensions/test_footnotes.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test_syntax/extensions/test_footnotes.py')
-rw-r--r--tests/test_syntax/extensions/test_footnotes.py36
1 files changed, 36 insertions, 0 deletions
diff --git a/tests/test_syntax/extensions/test_footnotes.py b/tests/test_syntax/extensions/test_footnotes.py
index 1a3a2b0..9a6b32a 100644
--- a/tests/test_syntax/extensions/test_footnotes.py
+++ b/tests/test_syntax/extensions/test_footnotes.py
@@ -300,3 +300,39 @@ class TestFootnotes(TestCase):
'</div>',
extension_configs={'footnotes': {'SEPARATOR': '-'}}
)
+
+ def test_backlink_title(self):
+ """Test backlink title configuration without placeholder."""
+
+ self.assertMarkdownRenders(
+ 'paragraph[^1]\n\n[^1]: A Footnote',
+ '<p>paragraph<sup id="fnref:1"><a class="footnote-ref" href="#fn:1">1</a></sup></p>\n'
+ '<div class="footnote">\n'
+ '<hr />\n'
+ '<ol>\n'
+ '<li id="fn:1">\n'
+ '<p>A Footnote&#160;<a class="footnote-backref" href="#fnref:1"'
+ ' title="Jump back to footnote">&#8617;</a></p>\n'
+ '</li>\n'
+ '</ol>\n'
+ '</div>',
+ extension_configs={'footnotes': {'BACKLINK_TITLE': 'Jump back to footnote'}}
+ )
+
+ def test_superscript_text(self):
+ """Test superscript text configuration."""
+
+ self.assertMarkdownRenders(
+ 'paragraph[^1]\n\n[^1]: A Footnote',
+ '<p>paragraph<sup id="fnref:1"><a class="footnote-ref" href="#fn:1">[1]</a></sup></p>\n'
+ '<div class="footnote">\n'
+ '<hr />\n'
+ '<ol>\n'
+ '<li id="fn:1">\n'
+ '<p>A Footnote&#160;<a class="footnote-backref" href="#fnref:1"'
+ ' title="Jump back to footnote 1 in the text">&#8617;</a></p>\n'
+ '</li>\n'
+ '</ol>\n'
+ '</div>',
+ extension_configs={'footnotes': {'SUPERSCRIPT_TEXT': '[{}]'}}
+ )