Fixed failing test

This commit is contained in:
Eliot Berriot 2018-04-02 19:15:27 +02:00
parent a252051351
commit 77c6bd5839
No known key found for this signature in database
GPG key ID: DD6965E2476E5C27
5 changed files with 54 additions and 30 deletions

View file

@ -175,29 +175,14 @@ class TestActor(SystemActor):
reply_url = 'https://{}/activities/note/{}'.format(
settings.FEDERATION_HOSTNAME, now.timestamp()
)
mention = '@{}@{}'.format(
sender.preferred_username,
sender.domain
)
reply_content = '{} Pong!'.format(
mention
sender.mention_username
)
reply_activity = {
"@context": [
"https://www.w3.org/ns/activitystreams",
"https://w3id.org/security/v1",
{
"manuallyApprovesFollowers": "as:manuallyApprovesFollowers",
"sensitive": "as:sensitive",
"movedTo": "as:movedTo",
"Hashtag": "as:Hashtag",
"ostatus": "http://ostatus.org#",
"atomUri": "ostatus:atomUri",
"inReplyToAtomUri": "ostatus:inReplyToAtomUri",
"conversation": "ostatus:conversation",
"toot": "http://joinmastodon.org/ns#",
"Emoji": "toot:Emoji"
}
{}
],
'type': 'Create',
'actor': test_actor.url,
@ -221,7 +206,7 @@ class TestActor(SystemActor):
{
"type": "Mention",
"href": ac['actor'],
"name": mention
"name": sender.mention_username
}
]
)