Do not boost if group is blocking poster

This commit is contained in:
tusooa 2023-11-07 21:16:24 -05:00
commit e34a975dd9
No known key found for this signature in database
GPG key ID: 42AEC43D48433C51
3 changed files with 34 additions and 1 deletions

View file

@ -1883,5 +1883,13 @@ defmodule Pleroma.Web.CommonAPITest do
announces = get_announces_of_object(post.object)
assert [_, _] = announces
end
test "it does not boost if group is blocking poster", %{poster: poster, group: group} do
{:ok, _} = CommonAPI.block(group, poster)
{:ok, post} = CommonAPI.post(poster, %{status: "hey @#{group.nickname}"})
announces = get_announces_of_object(post.object)
assert [] = announces
end
end
end