aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorAaron Tinio <aptinio@gmail.com>2019-05-15 07:59:24 +0800
committerAaron Tinio <aptinio@gmail.com>2019-05-16 05:53:51 +0800
commit2b6119dfbf47f118dfb102fc09f6450e59ccf15e (patch)
treef97ef60544b4726908f63839364462a806297ee4 /test
parent64495b96e9159b88ef0b4a6486e60b54722664fb (diff)
downloadpleroma-2b6119dfbf47f118dfb102fc09f6450e59ccf15e.tar.gz
Restrict reblogs of activities from blocked domains
Diffstat (limited to 'test')
-rw-r--r--test/web/activity_pub/activity_pub_test.exs9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/web/activity_pub/activity_pub_test.exs b/test/web/activity_pub/activity_pub_test.exs
index 442120ffd..dfee93f67 100644
--- a/test/web/activity_pub/activity_pub_test.exs
+++ b/test/web/activity_pub/activity_pub_test.exs
@@ -474,6 +474,15 @@ defmodule Pleroma.Web.ActivityPub.ActivityPubTest do
ActivityPub.fetch_activities([], %{"blocking_user" => user, "skip_preload" => true})
refute activity in activities
+
+ followed_user = insert(:user)
+ ActivityPub.follow(user, followed_user)
+ {:ok, repeat_activity, _} = CommonAPI.repeat(activity.id, followed_user)
+
+ activities =
+ ActivityPub.fetch_activities([], %{"blocking_user" => user, "skip_preload" => true})
+
+ refute repeat_activity in activities
end
test "doesn't return muted activities" do