Merge remote-tracking branch 'remotes/origin/develop' into feature/object-hashtags...
[akkoma] / test / pleroma / web / mastodon_api / controllers / follow_request_controller_test.exs
index 6749e0e83a480dcf843b2348735cc2b3bc9e6a4c..f0a466212ffdd1de1d01257b3cd3d24a5dc65b9e 100644 (file)
@@ -3,7 +3,7 @@
 # SPDX-License-Identifier: AGPL-3.0-only
 
 defmodule Pleroma.Web.MastodonAPI.FollowRequestControllerTest do
-  use Pleroma.Web.ConnCase
+  use Pleroma.Web.ConnCase, async: true
 
   alias Pleroma.User
   alias Pleroma.Web.CommonAPI
@@ -12,7 +12,7 @@ defmodule Pleroma.Web.MastodonAPI.FollowRequestControllerTest do
 
   describe "locked accounts" do
     setup do
-      user = insert(:user, locked: true)
+      user = insert(:user, is_locked: true)
       %{conn: conn} = oauth_access(["follow"], user: user)
       %{user: user, conn: conn}
     end
@@ -21,7 +21,7 @@ defmodule Pleroma.Web.MastodonAPI.FollowRequestControllerTest do
       other_user = insert(:user)
 
       {:ok, _, _, _activity} = CommonAPI.follow(other_user, user)
-      {:ok, other_user} = User.follow(other_user, user, :follow_pending)
+      {:ok, other_user, user} = User.follow(other_user, user, :follow_pending)
 
       assert User.following?(other_user, user) == false
 
@@ -35,7 +35,7 @@ defmodule Pleroma.Web.MastodonAPI.FollowRequestControllerTest do
       other_user = insert(:user)
 
       {:ok, _, _, _activity} = CommonAPI.follow(other_user, user)
-      {:ok, other_user} = User.follow(other_user, user, :follow_pending)
+      {:ok, other_user, user} = User.follow(other_user, user, :follow_pending)
 
       user = User.get_cached_by_id(user.id)
       other_user = User.get_cached_by_id(other_user.id)