diff options
author | Andrew Godwin | 2022-12-04 20:22:24 -0700 |
---|---|---|
committer | Andrew Godwin | 2022-12-04 20:23:02 -0700 |
commit | 6291fa0f5c4d30139c23c2e2f2a1daa49852c105 (patch) | |
tree | e6b904f84fe42448839e4cc5dab3ad0aaccbcabe /tests/activities/models | |
parent | d27be3f42619e9eaf3b8ac9333b2bf5bb290aae6 (diff) | |
download | takahe-6291fa0f5c4d30139c23c2e2f2a1daa49852c105.tar.gz takahe-6291fa0f5c4d30139c23c2e2f2a1daa49852c105.tar.bz2 takahe-6291fa0f5c4d30139c23c2e2f2a1daa49852c105.zip |
Fix mentions in replies/capitalisation
Diffstat (limited to 'tests/activities/models')
-rw-r--r-- | tests/activities/models/test_post.py | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/activities/models/test_post.py b/tests/activities/models/test_post.py index baeb55a..d215be0 100644 --- a/tests/activities/models/test_post.py +++ b/tests/activities/models/test_post.py @@ -68,6 +68,17 @@ def test_linkify_mentions_remote(identity, remote_identity): local=True, ) assert post.safe_content_remote() == "<p>@test@example.com, welcome!</p>" + # Test case insensitivity (remote) + post = Post.objects.create( + content="<p>Hey @TeSt</p>", + author=identity, + local=True, + ) + post.mentions.add(remote_identity) + assert ( + post.safe_content_remote() + == '<p>Hey <a href="https://remote.test/@test/">@test</a></p>' + ) @pytest.mark.django_db |