summaryrefslogtreecommitdiff
path: root/test/web/common_api/common_api_test.exs
diff options
context:
space:
mode:
authorrinpatch <rinpatch@sdf.org>2020-08-04 19:17:30 +0000
committerrinpatch <rinpatch@sdf.org>2020-08-04 19:17:30 +0000
commitb1b6a7dfa890a6ae16f49d2f91e2ebdbaecf1724 (patch)
tree74c5ef004429c45a4d801ee9e18170ec22174464 /test/web/common_api/common_api_test.exs
parentfede37e4c650de07949f5e29e27d992d9ca55d5d (diff)
parent36aa34a1a8c489f74a9821095d823f8060afac5f (diff)
downloadpleroma-b1b6a7dfa890a6ae16f49d2f91e2ebdbaecf1724.tar.gz
pleroma-b1b6a7dfa890a6ae16f49d2f91e2ebdbaecf1724.zip
Merge branch 'deactivated-user-posts' into 'develop'
Deactivated user posts Closes #2011 See merge request pleroma/pleroma!2845
Diffstat (limited to 'test/web/common_api/common_api_test.exs')
-rw-r--r--test/web/common_api/common_api_test.exs5
1 files changed, 5 insertions, 0 deletions
diff --git a/test/web/common_api/common_api_test.exs b/test/web/common_api/common_api_test.exs
index 313dda21b..4ba6232dc 100644
--- a/test/web/common_api/common_api_test.exs
+++ b/test/web/common_api/common_api_test.exs
@@ -458,6 +458,11 @@ defmodule Pleroma.Web.CommonAPITest do
end
describe "posting" do
+ test "deactivated users can't post" do
+ user = insert(:user, deactivated: true)
+ assert {:error, _} = CommonAPI.post(user, %{status: "ye"})
+ end
+
test "it supports explicit addressing" do
user = insert(:user)
user_two = insert(:user)