logo

pleroma

My custom branche(s) on git.pleroma.social/pleroma/pleroma

mastodon_api_controller_test.exs (971B)


  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. defmodule Pleroma.Web.MastodonAPI.MastodonAPIControllerTest do
  5. use Pleroma.Web.ConnCase
  6. describe "empty_array/2 (stubs)" do
  7. test "GET /api/v1/accounts/:id/identity_proofs" do
  8. %{user: user, conn: conn} = oauth_access(["read:accounts"])
  9. assert [] ==
  10. conn
  11. |> get("/api/v1/accounts/#{user.id}/identity_proofs")
  12. |> json_response(200)
  13. end
  14. test "GET /api/v1/endorsements" do
  15. %{conn: conn} = oauth_access(["read:accounts"])
  16. assert [] ==
  17. conn
  18. |> get("/api/v1/endorsements")
  19. |> json_response(200)
  20. end
  21. test "GET /api/v1/trends", %{conn: conn} do
  22. assert [] ==
  23. conn
  24. |> get("/api/v1/trends")
  25. |> json_response(200)
  26. end
  27. end
  28. end