summaryrefslogtreecommitdiff
path: root/test/web/mastodon_api/views
diff options
context:
space:
mode:
authorEgor Kislitsyn <egor@kislitsyn.com>2020-01-15 16:49:45 +0400
committerEgor Kislitsyn <egor@kislitsyn.com>2020-01-15 16:49:45 +0400
commit3849053c6adbb4024e8fbe60e908cb141204f594 (patch)
tree173a6a4283e37e90209da9f347d2954cf7be5e1a /test/web/mastodon_api/views
parent34d85f8a5473fe0f85e8a8e9e8f58e40b3964ba4 (diff)
parent77412d5dd24a384f9be7d6bc6b1538415c584802 (diff)
downloadpleroma-3849053c6adbb4024e8fbe60e908cb141204f594.tar.gz
pleroma-3849053c6adbb4024e8fbe60e908cb141204f594.zip
Merge branch 'develop' into notifications-from-account
Diffstat (limited to 'test/web/mastodon_api/views')
-rw-r--r--test/web/mastodon_api/views/status_view_test.exs15
1 files changed, 15 insertions, 0 deletions
diff --git a/test/web/mastodon_api/views/status_view_test.exs b/test/web/mastodon_api/views/status_view_test.exs
index bdd87a79e..17b6ebcbc 100644
--- a/test/web/mastodon_api/views/status_view_test.exs
+++ b/test/web/mastodon_api/views/status_view_test.exs
@@ -394,6 +394,21 @@ defmodule Pleroma.Web.MastodonAPI.StatusViewTest do
assert length(represented[:media_attachments]) == 1
end
+ test "a Mobilizon event" do
+ user = insert(:user)
+
+ {:ok, object} =
+ Pleroma.Object.Fetcher.fetch_object_from_id(
+ "https://mobilizon.org/events/252d5816-00a3-4a89-a66f-15bf65c33e39"
+ )
+
+ %Activity{} = activity = Activity.get_create_by_object_ap_id(object.data["id"])
+
+ represented = StatusView.render("show.json", %{for: user, activity: activity})
+
+ assert represented[:id] == to_string(activity.id)
+ end
+
describe "build_tags/1" do
test "it returns a a dictionary tags" do
object_tags = [