X-Git-Url: http://git.squeep.com/?a=blobdiff_plain;ds=sidebyside;f=test%2Fweb%2Fmastodon_api%2Fstatus_view_test.exs;h=f957fedac6bd8d1e6bbdd039dc0d8dd1f515a42c;hb=d03a116654bd7c4329b698a0f175e37aea8c2caa;hp=e33479368d9ed5cec9c925656d5e7e605a069da2;hpb=4a278cd80a02fa1882db17397bb97b155c76570e;p=akkoma diff --git a/test/web/mastodon_api/status_view_test.exs b/test/web/mastodon_api/status_view_test.exs index e33479368..f957fedac 100644 --- a/test/web/mastodon_api/status_view_test.exs +++ b/test/web/mastodon_api/status_view_test.exs @@ -84,6 +84,7 @@ defmodule Pleroma.Web.MastodonAPI.StatusViewTest do account: AccountView.render("account.json", %{user: user}), in_reply_to_id: nil, in_reply_to_account_id: nil, + card: nil, reblog: nil, content: HtmlSanitizeEx.basic_html(note.data["object"]["content"]), created_at: created_at, @@ -149,7 +150,10 @@ defmodule Pleroma.Web.MastodonAPI.StatusViewTest do status = StatusView.render("status.json", %{activity: activity}) - assert status.mentions == [AccountView.render("mention.json", %{user: user})] + actor = Repo.get_by(User, ap_id: activity.actor) + + assert status.mentions == + Enum.map([user, actor], fn u -> AccountView.render("mention.json", %{user: u}) end) end test "attachments" do