logo

pleroma

My custom branche(s) on git.pleroma.social/pleroma/pleroma git clone https://hacktivis.me/git/pleroma.git
commit: cb2a072e6252b7c3f6473f7cfd1af5c0ec732d7b
parent 2e4a1c56c36fcd4b9ef34bd3a771abfe21cc71d5
Author: Alex Gleason <alex@alexgleason.me>
Date:   Mon, 27 Dec 2021 18:29:03 -0600

Apps: add test for get_user_apps/1

Diffstat:

Mtest/pleroma/web/o_auth/app_test.exs12++++++++++++
1 file changed, 12 insertions(+), 0 deletions(-)

diff --git a/test/pleroma/web/o_auth/app_test.exs b/test/pleroma/web/o_auth/app_test.exs @@ -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