diff options
author | Roger Braun <roger@rogerbraun.net> | 2017-04-30 11:16:41 +0200 |
---|---|---|
committer | Roger Braun <roger@rogerbraun.net> | 2017-04-30 11:16:41 +0200 |
commit | 9d7c3190cc346bf2a5576b6b93c26723059ae9a1 (patch) | |
tree | 257225f5f94a119a8f7aa061bd70a13714c72909 /test/activity_test.exs | |
parent | 11ea08649d5a5e5d2ac9ee29406f53240be77ec4 (diff) | |
download | pleroma-9d7c3190cc346bf2a5576b6b93c26723059ae9a1.tar.gz pleroma-9d7c3190cc346bf2a5576b6b93c26723059ae9a1.zip |
Get create activity from created object id.
This is useful for Ostatus federation because ostatus doesn't have
different ids for objects and activities...
Diffstat (limited to 'test/activity_test.exs')
-rw-r--r-- | test/activity_test.exs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test/activity_test.exs b/test/activity_test.exs index ce6eb1545..366a2f957 100644 --- a/test/activity_test.exs +++ b/test/activity_test.exs @@ -15,4 +15,11 @@ defmodule Pleroma.ActivityTest do assert activity == found_activity end + + test "returns the activity that created an object" do + activity = insert(:note_activity) + found_activity = Pleroma.Activity.get_create_activity_by_object_ap_id(activity.data["object"]["id"]) + + assert activity == found_activity + end end |