diff options
author | lain <lain@soykaf.club> | 2018-12-26 12:46:16 +0100 |
---|---|---|
committer | lain <lain@soykaf.club> | 2018-12-26 12:46:16 +0100 |
commit | 551d80cc0186424d2c1653f917749adea16d9963 (patch) | |
tree | 25c48f4e0b95705063d65164aa1eaa96f6b58acc /test | |
parent | 91724d160acc39585c37742204c59b91e59df569 (diff) | |
download | pleroma-551d80cc0186424d2c1653f917749adea16d9963.tar.gz |
Expose restricted names in nodeinfo.
Diffstat (limited to 'test')
-rw-r--r-- | test/web/node_info_test.exs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/test/web/node_info_test.exs b/test/web/node_info_test.exs index 6769a4490..5981c70a7 100644 --- a/test/web/node_info_test.exs +++ b/test/web/node_info_test.exs @@ -19,6 +19,17 @@ defmodule Pleroma.Web.NodeInfoTest do assert user.ap_id in result["metadata"]["staffAccounts"] end + test "nodeinfo shows restricted nicknames", %{conn: conn} do + conn = + conn + |> get("/nodeinfo/2.0.json") + + assert result = json_response(conn, 200) + + assert Pleroma.Config.get([Pleroma.User, :restricted_nicknames]) == + result["metadata"]["restrictedNicknames"] + end + test "returns 404 when federation is disabled", %{conn: conn} do instance = Application.get_env(:pleroma, :instance) |