summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/fixtures/mastodon-unfollow-activity.json63
-rw-r--r--test/web/activity_pub/activity_pub_test.exs2
2 files changed, 33 insertions, 32 deletions
diff --git a/test/fixtures/mastodon-unfollow-activity.json b/test/fixtures/mastodon-unfollow-activity.json
index 022b47acd..ae5ab7c66 100644
--- a/test/fixtures/mastodon-unfollow-activity.json
+++ b/test/fixtures/mastodon-unfollow-activity.json
@@ -1,33 +1,34 @@
{
- "@context": [
- "https://www.w3.org/ns/activitystreams",
- "https://w3id.org/security/v1",
- {
- "toot": "http://joinmastodon.org/ns#",
- "sensitive": "as:sensitive",
- "ostatus": "http://ostatus.org#",
- "movedTo": "as:movedTo",
- "manuallyApprovesFollowers": "as:manuallyApprovesFollowers",
- "inReplyToAtomUri": "ostatus:inReplyToAtomUri",
- "conversation": "ostatus:conversation",
- "atomUri": "ostatus:atomUri",
- "Hashtag": "as:Hashtag",
- "Emoji": "toot:Emoji"
- }
- ],
- "signature": {
- "type": "RsaSignature2017",
- "signatureValue": "Kn1/UkAQGJVaXBfWLAHcnwHg8YMAUqlEaBuYLazAG+pz5hqivsyrBmPV186Xzr+B4ZLExA9+SnOoNx/GOz4hBm0kAmukNSILAsUd84tcJ2yT9zc1RKtembK4WiwOw7li0+maeDN0HaB6t+6eTqsCWmtiZpprhXD8V1GGT8yG7X24fQ9oFGn+ng7lasbcCC0988Y1eGqNe7KryxcPuQz57YkDapvtONzk8gyLTkZMV4De93MyRHq6GVjQVIgtiYabQAxrX6Q8C+4P/jQoqdWJHEe+MY5JKyNaT/hMPt2Md1ok9fZQBGHlErk22/zy8bSN19GdG09HmIysBUHRYpBLig==",
- "creator": "http://mastodon.example.org/users/admin#main-key",
- "created": "2018-02-17T13:29:31Z"
- },
- "type": "Undo",
- "object": {
- "type": "Follow",
- "object": "http://localtesting.pleroma.lol/users/lain",
- "nickname": "lain",
- "id": "http://mastodon.example.org/users/admin#follows/2",
- "actor": "http://mastodon.example.org/users/admin"
- },
- "actor": "http://mastodon.example.org/users/admin"
+ "@context":[
+ "https://www.w3.org/ns/activitystreams",
+ "https://w3id.org/security/v1",
+ {
+ "toot":"http://joinmastodon.org/ns#",
+ "sensitive":"as:sensitive",
+ "ostatus":"http://ostatus.org#",
+ "movedTo":"as:movedTo",
+ "manuallyApprovesFollowers":"as:manuallyApprovesFollowers",
+ "inReplyToAtomUri":"ostatus:inReplyToAtomUri",
+ "conversation":"ostatus:conversation",
+ "atomUri":"ostatus:atomUri",
+ "Hashtag":"as:Hashtag",
+ "Emoji":"toot:Emoji"
+ }
+ ],
+ "signature":{
+ "type":"RsaSignature2017",
+ "signatureValue":"Kn1/UkAQGJVaXBfWLAHcnwHg8YMAUqlEaBuYLazAG+pz5hqivsyrBmPV186Xzr+B4ZLExA9+SnOoNx/GOz4hBm0kAmukNSILAsUd84tcJ2yT9zc1RKtembK4WiwOw7li0+maeDN0HaB6t+6eTqsCWmtiZpprhXD8V1GGT8yG7X24fQ9oFGn+ng7lasbcCC0988Y1eGqNe7KryxcPuQz57YkDapvtONzk8gyLTkZMV4De93MyRHq6GVjQVIgtiYabQAxrX6Q8C+4P/jQoqdWJHEe+MY5JKyNaT/hMPt2Md1ok9fZQBGHlErk22/zy8bSN19GdG09HmIysBUHRYpBLig==",
+ "creator":"http://mastodon.example.org/users/admin#main-key",
+ "created":"2018-02-17T13:29:31Z"
+ },
+ "type":"Undo",
+ "object":{
+ "type":"Follow",
+ "object":"http://localtesting.pleroma.lol/users/lain",
+ "nickname":"lain",
+ "id":"http://mastodon.example.org/users/admin#follows/2",
+ "actor":"http://mastodon.example.org/users/admin"
+ },
+ "actor":"http://mastodon.example.org/users/admin",
+ "id": "http://mastodon.example.org/users/admin#follow/2/undo"
}
diff --git a/test/web/activity_pub/activity_pub_test.exs b/test/web/activity_pub/activity_pub_test.exs
index 9adce84b5..35f0deffe 100644
--- a/test/web/activity_pub/activity_pub_test.exs
+++ b/test/web/activity_pub/activity_pub_test.exs
@@ -425,7 +425,7 @@ defmodule Pleroma.Web.ActivityPub.ActivityPubTest do
assert activity.data["type"] == "Undo"
assert activity.data["actor"] == follower.ap_id
- assert activity.data["object"] == follow_activity.data["id"]
+ assert activity.data["object"]["id"] == follow_activity.data["id"]
end
end