forked from AkkomaGang/akkoma
update changelog
This commit is contained in:
parent
51189ad365
commit
add26817e3
2 changed files with 25 additions and 19 deletions
|
@ -32,6 +32,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
|
||||||
- Pleroma API: Importing the mutes users from CSV files.
|
- Pleroma API: Importing the mutes users from CSV files.
|
||||||
- Admin API: Importing emoji from a zip file
|
- Admin API: Importing emoji from a zip file
|
||||||
- Pleroma API: Pagination for remote/local packs and emoji.
|
- Pleroma API: Pagination for remote/local packs and emoji.
|
||||||
|
- Admin API: (`GET /api/pleroma/admin/users`) added filters user by `unconfirmed` status
|
||||||
|
- Admin API: (`GET /api/pleroma/admin/users`) added filters user by `actor_type`
|
||||||
|
|
||||||
</details>
|
</details>
|
||||||
|
|
||||||
|
|
|
@ -671,12 +671,12 @@ test "only unapproved users", %{conn: conn} do
|
||||||
|
|
||||||
conn = get(conn, "/api/pleroma/admin/users?filters=need_approval")
|
conn = get(conn, "/api/pleroma/admin/users?filters=need_approval")
|
||||||
|
|
||||||
users =
|
users = [
|
||||||
[
|
user_response(
|
||||||
user_response(user,
|
user,
|
||||||
%{"approval_pending" => true, "registration_reason" => "Plz let me in!"}
|
%{"approval_pending" => true, "registration_reason" => "Plz let me in!"}
|
||||||
)
|
)
|
||||||
]
|
]
|
||||||
|
|
||||||
assert json_response(conn, 200) == %{
|
assert json_response(conn, 200) == %{
|
||||||
"count" => 1,
|
"count" => 1,
|
||||||
|
@ -724,9 +724,9 @@ test "load only moderators", %{conn: conn} do
|
||||||
"page_size" => 50,
|
"page_size" => 50,
|
||||||
"users" => [
|
"users" => [
|
||||||
user_response(moderator, %{
|
user_response(moderator, %{
|
||||||
"deactivated" => false,
|
"deactivated" => false,
|
||||||
"roles" => %{"admin" => false, "moderator" => true}
|
"roles" => %{"admin" => false, "moderator" => true}
|
||||||
})
|
})
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
@ -738,9 +738,10 @@ test "load users with actor_type is Person", %{admin: admin, conn: conn} do
|
||||||
user1 = insert(:user)
|
user1 = insert(:user)
|
||||||
user2 = insert(:user)
|
user2 = insert(:user)
|
||||||
|
|
||||||
response = conn
|
response =
|
||||||
|> get(user_path(conn, :list), %{actor_types: ["Person"]})
|
conn
|
||||||
|> json_response(200)
|
|> get(user_path(conn, :list), %{actor_types: ["Person"]})
|
||||||
|
|> json_response(200)
|
||||||
|
|
||||||
users =
|
users =
|
||||||
[
|
[
|
||||||
|
@ -760,9 +761,10 @@ test "load users with actor_type is Person and Service", %{admin: admin, conn: c
|
||||||
user1 = insert(:user)
|
user1 = insert(:user)
|
||||||
user2 = insert(:user)
|
user2 = insert(:user)
|
||||||
|
|
||||||
response = conn
|
response =
|
||||||
|> get(user_path(conn, :list), %{actor_types: ["Person", "Service"]})
|
conn
|
||||||
|> json_response(200)
|
|> get(user_path(conn, :list), %{actor_types: ["Person", "Service"]})
|
||||||
|
|> json_response(200)
|
||||||
|
|
||||||
users =
|
users =
|
||||||
[
|
[
|
||||||
|
@ -782,12 +784,14 @@ test "load users with actor_type is Service", %{conn: conn} do
|
||||||
insert(:user)
|
insert(:user)
|
||||||
insert(:user)
|
insert(:user)
|
||||||
|
|
||||||
response = conn
|
response =
|
||||||
|> get(user_path(conn, :list), %{actor_types: ["Service"]})
|
conn
|
||||||
|> json_response(200)
|
|> get(user_path(conn, :list), %{actor_types: ["Service"]})
|
||||||
|
|> json_response(200)
|
||||||
|
|
||||||
users = [user_response(user_service, %{"actor_type" => "Service"})]
|
users = [user_response(user_service, %{"actor_type" => "Service"})]
|
||||||
|
|
||||||
assert response == %{"count" => 1, "page_size" => 50, "users" => users }
|
assert response == %{"count" => 1, "page_size" => 50, "users" => users}
|
||||||
end
|
end
|
||||||
|
|
||||||
test "load users with tags list", %{conn: conn} do
|
test "load users with tags list", %{conn: conn} do
|
||||||
|
|
Loading…
Reference in a new issue