diff options
author | feld <feld@feld.me> | 2019-09-09 18:21:29 +0000 |
---|---|---|
committer | feld <feld@feld.me> | 2019-09-09 18:21:29 +0000 |
commit | edbaf781763a05037c1567f6f1a3ac1d35d60de2 (patch) | |
tree | 5cb615b34f409c21fddc7d79a935dcaf5102f80c /test | |
parent | c45013df8e53334bcc1afb8cd1df673c290037ee (diff) | |
parent | e0f84d0043d922f7cc88875a0bc52f2db8972b76 (diff) | |
download | pleroma-edbaf781763a05037c1567f6f1a3ac1d35d60de2.tar.gz |
Merge branch 'fix/read-inbox' into 'develop'
Fix `ActivityPubController.read_inbox/2`
Closes #1248
See merge request pleroma/pleroma!1649
Diffstat (limited to 'test')
-rw-r--r-- | test/web/activity_pub/activity_pub_controller_test.exs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/test/web/activity_pub/activity_pub_controller_test.exs b/test/web/activity_pub/activity_pub_controller_test.exs index 5192e734f..4388538c2 100644 --- a/test/web/activity_pub/activity_pub_controller_test.exs +++ b/test/web/activity_pub/activity_pub_controller_test.exs @@ -365,6 +365,17 @@ defmodule Pleroma.Web.ActivityPub.ActivityPubControllerTest do assert json_response(conn, 403) end + test "it doesn't crash without an authenticated user", %{conn: conn} do + user = insert(:user) + + conn = + conn + |> put_req_header("accept", "application/activity+json") + |> get("/users/#{user.nickname}/inbox") + + assert json_response(conn, 403) + end + test "it returns a note activity in a collection", %{conn: conn} do note_activity = insert(:direct_note_activity) note_object = Object.normalize(note_activity) |