diff options
author | lambda <pleromagit@rogerbraun.net> | 2017-11-07 18:58:22 +0000 |
---|---|---|
committer | lambda <pleromagit@rogerbraun.net> | 2017-11-07 18:58:22 +0000 |
commit | d761b1543af537fb6f1013c0930449c7c6a26941 (patch) | |
tree | 61fa46bbafd9eacd0ea1d853a2ff050f93922936 /test/web/twitter_api/twitter_api_controller_test.exs | |
parent | f801b695d796f3708d44497fa698cfb11e9d83c7 (diff) | |
parent | f85566324ec7cf20f070850d0cd5bd3fec25445d (diff) | |
download | pleroma-d761b1543af537fb6f1013c0930449c7c6a26941.tar.gz |
Merge branch 'authenticated-profile-fetching' into 'develop'
Allow profile fetching for authenticated users only.
Closes #54
See merge request pleroma/pleroma!7
Diffstat (limited to 'test/web/twitter_api/twitter_api_controller_test.exs')
-rw-r--r-- | test/web/twitter_api/twitter_api_controller_test.exs | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/test/web/twitter_api/twitter_api_controller_test.exs b/test/web/twitter_api/twitter_api_controller_test.exs index a62947018..798309f7d 100644 --- a/test/web/twitter_api/twitter_api_controller_test.exs +++ b/test/web/twitter_api/twitter_api_controller_test.exs @@ -405,11 +405,13 @@ defmodule Pleroma.Web.TwitterAPI.ControllerTest do describe "GET /api/externalprofile/show" do test "it returns the user", %{conn: conn} do user = insert(:user) + other_user = insert(:user) conn = conn - |> get("/api/externalprofile/show", %{profileurl: user.ap_id}) + |> assign(:user, user) + |> get("/api/externalprofile/show", %{profileurl: other_user.ap_id}) - assert json_response(conn, 200) == UserView.render("show.json", %{user: user}) + assert json_response(conn, 200) == UserView.render("show.json", %{user: other_user}) end end |