aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/web/activity_pub/object_validator_test.exs9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/web/activity_pub/object_validator_test.exs b/test/web/activity_pub/object_validator_test.exs
index 8230ae0d9..bc2317e55 100644
--- a/test/web/activity_pub/object_validator_test.exs
+++ b/test/web/activity_pub/object_validator_test.exs
@@ -33,6 +33,15 @@ defmodule Pleroma.Web.ActivityPub.ObjectValidatorTest do
refute match?({:ok, _object, _meta}, ObjectValidator.validate(valid_chat_message, []))
end
+ test "does not validate if the recipient is blocking the actor", %{
+ valid_chat_message: valid_chat_message,
+ user: user,
+ recipient: recipient
+ } do
+ Pleroma.User.block(recipient, user)
+ refute match?({:ok, _object, _meta}, ObjectValidator.validate(valid_chat_message, []))
+ end
+
test "does not validate if the actor or the recipient is not in our system", %{
valid_chat_message: valid_chat_message
} do