Enforcement of OAuth scopes check for authenticated API endpoints, :skip_plug plug...
[akkoma] / test / web / mastodon_api / controllers / suggestion_controller_test.exs
1 # Pleroma: A lightweight social networking server
2 # Copyright © 2017-2020 Pleroma Authors <https://pleroma.social/>
3 # SPDX-License-Identifier: AGPL-3.0-only
4
5 defmodule Pleroma.Web.MastodonAPI.SuggestionControllerTest do
6 use Pleroma.Web.ConnCase
7
8 alias Pleroma.Config
9
10 setup do: oauth_access(["read"])
11
12 test "returns empty result", %{conn: conn} do
13 res =
14 conn
15 |> get("/api/v1/suggestions")
16 |> json_response(200)
17
18 assert res == []
19 end
20 end