aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorAlex Gleason <alex@alexgleason.me>2022-01-28 12:33:07 -0600
committerAlex Gleason <alex@alexgleason.me>2022-01-28 12:33:55 -0600
commit5134e691f4f6582e807f49ea2760c0dd44dce805 (patch)
tree0dc64ec69750bfe21257379a00e6130ae6228756 /test
parenta3d65937ab7af163e56d8b062cbc1bf4ca7b4568 (diff)
downloadpleroma-5134e691f4f6582e807f49ea2760c0dd44dce805.tar.gz
StatusView: return quote post inside a reblog
Diffstat (limited to 'test')
-rw-r--r--test/pleroma/web/mastodon_api/views/status_view_test.exs12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/pleroma/web/mastodon_api/views/status_view_test.exs b/test/pleroma/web/mastodon_api/views/status_view_test.exs
index 446ade626..1bfe6141a 100644
--- a/test/pleroma/web/mastodon_api/views/status_view_test.exs
+++ b/test/pleroma/web/mastodon_api/views/status_view_test.exs
@@ -445,6 +445,18 @@ defmodule Pleroma.Web.MastodonAPI.StatusViewTest do
refute status.pleroma.quote_visible
end
+ test "repost of quote post" do
+ post = insert(:note_activity)
+ user = insert(:user)
+
+ {:ok, quote_post} = CommonAPI.post(user, %{status: "he", quote_id: post.id})
+ {:ok, repost} = CommonAPI.repeat(quote_post.id, user)
+
+ [status] = StatusView.render("index.json", %{activities: [repost], as: :activity})
+
+ assert status.reblog.pleroma.quote.id == to_string(post.id)
+ end
+
test "contains mentions" do
user = insert(:user)
mentioned = insert(:user)