diff options
author | kaniini <ariadne@dereferenced.org> | 2019-07-16 11:14:46 +0000 |
---|---|---|
committer | kaniini <ariadne@dereferenced.org> | 2019-07-16 11:14:46 +0000 |
commit | d3b922276138cf7aaa896d52a8e35113a40e22dc (patch) | |
tree | ed02c143d7298736e821a507acd01d3931249a3f /test | |
parent | a0d71d3ccfeece9deab213a627720dfc2aaf51be (diff) | |
parent | 520ee6c59162c26caf032b2d16ca975c99b5beb5 (diff) | |
download | pleroma-d3b922276138cf7aaa896d52a8e35113a40e22dc.tar.gz |
Merge branch 'add-deactivated-to-account-view' into 'develop'
Add `pleroma.deactivated` to the Account entity (Mastodon API)
See merge request pleroma/pleroma!1433
Diffstat (limited to 'test')
-rw-r--r-- | test/web/mastodon_api/account_view_test.exs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test/web/mastodon_api/account_view_test.exs b/test/web/mastodon_api/account_view_test.exs index 83b9db071..fa44d35cc 100644 --- a/test/web/mastodon_api/account_view_test.exs +++ b/test/web/mastodon_api/account_view_test.exs @@ -153,6 +153,13 @@ defmodule Pleroma.Web.MastodonAPI.AccountViewTest do assert expected == AccountView.render("account.json", %{user: user}) end + test "Represent a deactivated user for an admin" do + admin = insert(:user, %{info: %{is_admin: true}}) + deactivated_user = insert(:user, %{info: %{deactivated: true}}) + represented = AccountView.render("account.json", %{user: deactivated_user, for: admin}) + assert represented[:pleroma][:deactivated] == true + end + test "Represent a smaller mention" do user = insert(:user) |