Render hashtag links with data-mention="hashtag" attribute
This commit is contained in:
parent
276b255f32
commit
f3334b1550
5 changed files with 13 additions and 7 deletions
|
@ -359,8 +359,10 @@ class StatusViews(TestCase):
|
|||
hashtag_new = models.Hashtag.objects.filter(name="#new").first()
|
||||
self.assertEqual(
|
||||
status.content,
|
||||
f'<p>this is an <a href="{hashtag_exising.remote_id}">#existing</a> '
|
||||
+ f'hashtag, this one is <a href="{hashtag_new.remote_id}">#new</a>.</p>',
|
||||
"<p>this is an "
|
||||
+ f'<a href="{hashtag_exising.remote_id}" data-mention="hashtag">'
|
||||
+ "#existing</a> hashtag, this one is "
|
||||
+ f'<a href="{hashtag_new.remote_id}" data-mention="hashtag">#new</a>.</p>',
|
||||
)
|
||||
|
||||
def test_find_hashtags(self, *_):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue