X-Git-Url: https://git.squeep.com/?a=blobdiff_plain;ds=sidebyside;f=test%2Fuser_test.exs;h=92de31c748a3c5259fd772b0a00a55cc63e293c5;hb=cd0218c2053b3f7e04416ea0eb12759d78cfcbf5;hp=3d5b382c896af1c97a9e7590d7e69514570f3aeb;hpb=c6fdfbc4f14b855d9cdf2d757ff2c43282aabe90;p=akkoma diff --git a/test/user_test.exs b/test/user_test.exs index 3d5b382c8..92de31c74 100644 --- a/test/user_test.exs +++ b/test/user_test.exs @@ -1231,6 +1231,20 @@ defmodule Pleroma.UserTest do end end + describe "invisible?/1" do + test "returns true for an invisible user" do + user = insert(:user, local: true, invisible: true) + + assert User.invisible?(user) + end + + test "returns false for a non-invisible user" do + user = insert(:user, local: true) + + refute User.invisible?(user) + end + end + describe "visible_for?/2" do test "returns true when the account is itself" do user = insert(:user, local: true)