This commit is contained in:
Maksim Pechnikov 2020-10-31 08:54:29 +03:00 committed by Alexander Strizhakov
parent 099c5e81c3
commit a09fae8820
No known key found for this signature in database
GPG Key ID: 022896A53AEF1381

View File

@ -379,7 +379,9 @@ defmodule Pleroma.Web.AdminAPI.UserControllerTest do
describe "GET /api/pleroma/admin/users" do
test "renders users array for the first page", %{conn: conn, admin: admin} do
user = insert(:user, local: false, tags: ["foo", "bar"])
user =
insert(:user, local: false, tags: [build(:tag, name: "foo"), build(:tag, name: "bar")])
user2 = insert(:user, is_approved: false, registration_reason: "I'm a chill dude")
conn = get(conn, "/api/pleroma/admin/users?page=1")
@ -745,8 +747,8 @@ defmodule Pleroma.Web.AdminAPI.UserControllerTest do
end
test "load users with tags list", %{conn: conn} do
user1 = insert(:user, tags: ["first"])
user2 = insert(:user, tags: ["second"])
user1 = insert(:user, tags: [build(:tag, name: "first")])
user2 = insert(:user, tags: [build(:tag, name: "second")])
insert(:user)
insert(:user)