X-Git-Url: http://git.squeep.com/?a=blobdiff_plain;f=test%2Fweb%2Factivity_pub%2Factivity_pub_controller_test.exs;h=957687c43143be04b17286ba28c741e76479a969;hb=5e36b750c1f98c440f4edcb9bb5bac5e6f93278f;hp=21ed28cf28b82ba7d6c1fb63350358131031d579;hpb=b331cb449a46bbead19fea4fba59762c1a2e3a10;p=akkoma diff --git a/test/web/activity_pub/activity_pub_controller_test.exs b/test/web/activity_pub/activity_pub_controller_test.exs index 21ed28cf2..957687c43 100644 --- a/test/web/activity_pub/activity_pub_controller_test.exs +++ b/test/web/activity_pub/activity_pub_controller_test.exs @@ -32,8 +32,15 @@ defmodule Pleroma.Web.ActivityPub.ActivityPubControllerTest do end describe "/users/:nickname/inbox" do - test "it inserts an incoming activity into the database" do - assert false + test "it inserts an incoming activity into the database", %{conn: conn} do + data = File.read!("test/fixtures/mastodon-post-activity.json") |> Poison.decode! + + conn = conn + |> assign(:valid_signature, true) + |> put_req_header("content-type", "application/activity+json") + |> post("/users/doesntmatter/inbox", data) + + assert "ok" == json_response(conn, 200) end end end