X-Git-Url: http://git.squeep.com/?a=blobdiff_plain;f=test%2Fpleroma%2Fweb%2Fmastodon_api%2Fviews%2Faccount_view_test.exs;h=5373a17c38f84a0db34a20ef213e0812daadd7b3;hb=f0208980e48ee361f9eaa40352f519a1b95ace28;hp=f9afd0afc2ca54089eb003e14588b8362b7170d4;hpb=fee0c6a2cb058282ee6c3960730201f58b691270;p=akkoma
diff --git a/test/pleroma/web/mastodon_api/views/account_view_test.exs b/test/pleroma/web/mastodon_api/views/account_view_test.exs
index f9afd0afc..5373a17c3 100644
--- a/test/pleroma/web/mastodon_api/views/account_view_test.exs
+++ b/test/pleroma/web/mastodon_api/views/account_view_test.exs
@@ -1,11 +1,10 @@
# Pleroma: A lightweight social networking server
-# Copyright © 2017-2020 Pleroma Authors
+# Copyright © 2017-2021 Pleroma Authors
# SPDX-License-Identifier: AGPL-3.0-only
defmodule Pleroma.Web.MastodonAPI.AccountViewTest do
use Pleroma.DataCase
- alias Pleroma.Config
alias Pleroma.User
alias Pleroma.UserRelationship
alias Pleroma.Web.CommonAPI
@@ -74,12 +73,13 @@ defmodule Pleroma.Web.MastodonAPI.AccountViewTest do
},
fields: []
},
+ fqn: "shp@shitposter.club",
pleroma: %{
ap_id: user.ap_id,
also_known_as: ["https://shitposter.zone/users/shp"],
background_image: "https://example.com/images/asuka_hospital.png",
favicon: nil,
- confirmation_pending: false,
+ is_confirmed: true,
tags: [],
is_admin: false,
is_moderator: false,
@@ -173,12 +173,13 @@ defmodule Pleroma.Web.MastodonAPI.AccountViewTest do
},
fields: []
},
+ fqn: "shp@shitposter.club",
pleroma: %{
ap_id: user.ap_id,
also_known_as: [],
background_image: nil,
favicon: nil,
- confirmation_pending: false,
+ is_confirmed: true,
tags: [],
is_admin: false,
is_moderator: false,
@@ -211,7 +212,7 @@ defmodule Pleroma.Web.MastodonAPI.AccountViewTest do
test "Represent a deactivated user for an admin" do
admin = insert(:user, is_admin: true)
- deactivated_user = insert(:user, deactivated: true)
+ deactivated_user = insert(:user, is_active: false)
represented = AccountView.render("show.json", %{user: deactivated_user, for: admin})
assert represented[:pleroma][:deactivated] == true
end
@@ -556,7 +557,7 @@ defmodule Pleroma.Web.MastodonAPI.AccountViewTest do
)
with media_preview_enabled <- [false, true] do
- Config.put([:media_preview_proxy, :enabled], media_preview_enabled)
+ clear_config([:media_preview_proxy, :enabled], media_preview_enabled)
AccountView.render("show.json", %{user: user, skip_visibility_check: true})
|> Enum.all?(fn