diff options
author | kaniini <nenolod@gmail.com> | 2019-01-05 22:29:08 +0000 |
---|---|---|
committer | kaniini <nenolod@gmail.com> | 2019-01-05 22:29:08 +0000 |
commit | 576368237ce3c8f07acb19ab02f3f9df84b42e4b (patch) | |
tree | 282b4f640c6c12fbc6d2928970b62f42edd06138 /test/web | |
parent | 145d6fe6e9f3c9414b1231da7f200e007413b31b (diff) | |
parent | 2d7da5f4375164aa78e221ab054529a04d09e819 (diff) | |
download | pleroma-576368237ce3c8f07acb19ab02f3f9df84b42e4b.tar.gz |
Merge branch 'activitypub-tombstone-fix' into 'develop'
Don't crash on AP request for tombstone
See merge request pleroma/pleroma!630
Diffstat (limited to 'test/web')
-rw-r--r-- | test/web/activity_pub/activity_pub_controller_test.exs | 12 |
1 files changed, 12 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 620e03674..7d1fe184e 100644 --- a/test/web/activity_pub/activity_pub_controller_test.exs +++ b/test/web/activity_pub/activity_pub_controller_test.exs @@ -75,6 +75,18 @@ defmodule Pleroma.Web.ActivityPub.ActivityPubControllerTest do assert json_response(conn, 404) end + + test "it returns 404 for tombstone objects", %{conn: conn} do + tombstone = insert(:tombstone) + uuid = String.split(tombstone.data["id"], "/") |> List.last() + + conn = + conn + |> put_req_header("accept", "application/activity+json") + |> get("/objects/#{uuid}") + + assert json_response(conn, 404) + end end describe "/inbox" do |