Merge branch 'develop' into refactor/deactivated_user_field
This commit is contained in:
commit
537ba1c5e0
48 changed files with 1066 additions and 214 deletions
|
|
@ -744,6 +744,22 @@ defmodule Pleroma.Web.CommonAPITest do
|
|||
refute Visibility.visible_for_user?(announce_activity, nil)
|
||||
end
|
||||
|
||||
test "author can repeat own private statuses" do
|
||||
author = insert(:user)
|
||||
follower = insert(:user)
|
||||
CommonAPI.follow(follower, author)
|
||||
|
||||
{:ok, activity} = CommonAPI.post(author, %{status: "cofe", visibility: "private"})
|
||||
|
||||
{:ok, %Activity{} = announce_activity} = CommonAPI.repeat(activity.id, author)
|
||||
|
||||
assert Visibility.is_private?(announce_activity)
|
||||
refute Visibility.visible_for_user?(announce_activity, nil)
|
||||
|
||||
assert Visibility.visible_for_user?(activity, follower)
|
||||
assert {:error, :not_found} = CommonAPI.repeat(activity.id, follower)
|
||||
end
|
||||
|
||||
test "favoriting a status" do
|
||||
user = insert(:user)
|
||||
other_user = insert(:user)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue