diff options
author | lain <lain@soykaf.club> | 2019-02-22 12:02:51 +0100 |
---|---|---|
committer | lain <lain@soykaf.club> | 2019-02-22 12:02:51 +0100 |
commit | 62296f5a251e376bed5b234a66b20226dbd58419 (patch) | |
tree | bcf1d09061ae7080fd1ec75b1b4329756f3c82d9 /test | |
parent | 5a4e2905fecfd21cf92f6b2844f15f5ee84b33f5 (diff) | |
download | pleroma-62296f5a251e376bed5b234a66b20226dbd58419.tar.gz |
Fix private post card handling.
Diffstat (limited to 'test')
-rw-r--r-- | test/web/mastodon_api/mastodon_api_controller_test.exs | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/test/web/mastodon_api/mastodon_api_controller_test.exs b/test/web/mastodon_api/mastodon_api_controller_test.exs index 3dfbc8669..b52c2b805 100644 --- a/test/web/mastodon_api/mastodon_api_controller_test.exs +++ b/test/web/mastodon_api/mastodon_api_controller_test.exs @@ -1744,6 +1744,18 @@ defmodule Pleroma.Web.MastodonAPI.MastodonAPIControllerTest do } } + # works with private posts + {:ok, activity} = + CommonAPI.post(user, %{"status" => "http://example.com/ogp", "visibility" => "direct"}) + + response_two = + conn + |> assign(:user, user) + |> get("/api/v1/statuses/#{activity.id}/card") + |> json_response(200) + + assert response_two == response + Pleroma.Config.put([:rich_media, :enabled], false) end end |