mirror of
https://github.com/getpelican/pelican.git
synced 2025-10-15 20:28:56 +02:00
Merge pull request #1854 from ingwinlu/summary_replacer
Test if summary is parsed by replacer
This commit is contained in:
commit
d3f306505e
1 changed files with 13 additions and 0 deletions
|
|
@ -316,6 +316,19 @@ class TestPage(LoggedTestCase):
|
||||||
'?utm_whatever=234&highlight=word#section-2">link</a>'
|
'?utm_whatever=234&highlight=word#section-2">link</a>'
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# also test for summary in metadata
|
||||||
|
args['metadata']['summary'] = (
|
||||||
|
'A simple summary test, with a '
|
||||||
|
'<a href="|filename|article.rst">link</a>'
|
||||||
|
)
|
||||||
|
args['context']['localsiteurl'] = 'http://notmyidea.org'
|
||||||
|
p = Page(**args)
|
||||||
|
self.assertEqual(
|
||||||
|
p.summary,
|
||||||
|
'A simple summary test, with a '
|
||||||
|
'<a href="http://notmyidea.org/article.html">link</a>'
|
||||||
|
)
|
||||||
|
|
||||||
def test_intrasite_link_more(self):
|
def test_intrasite_link_more(self):
|
||||||
# type does not take unicode in PY2 and bytes in PY3, which in
|
# type does not take unicode in PY2 and bytes in PY3, which in
|
||||||
# combination with unicode literals leads to following insane line:
|
# combination with unicode literals leads to following insane line:
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue