Apps: add test for get_user_apps/1

This commit is contained in:
Alex Gleason 2021-12-27 18:29:03 -06:00
parent 2e4a1c56c3
commit cb2a072e62
No known key found for this signature in database
GPG Key ID: 7211D1F99744FBB7

View File

@ -41,4 +41,16 @@ defmodule Pleroma.Web.OAuth.AppTest do
assert error.type == :unique
end
end
test "get_user_apps/1" do
user = insert(:user)
apps = [
insert(:oauth_app, user_id: user.id),
insert(:oauth_app, user_id: user.id),
insert(:oauth_app, user_id: user.id)
]
assert App.get_user_apps(user) == apps
end
end