Merge branch 'develop' into dtluna/pleroma-feature/unfollow-activity
[akkoma] / test / web / ostatus / ostatus_controller_test.exs
index 229cd9b1e1c214980eafdb8b00f4e6e4df8ce7bd..8b7ca4d8933dcbbe5191ebf6d98672a79a7637a8 100644 (file)
@@ -12,4 +12,15 @@ defmodule Pleroma.Web.OStatus.OStatusControllerTest do
 
     assert response(conn, 200)
   end
+
+  test "gets an object", %{conn: conn} do
+    note_activity = insert(:note_activity)
+    [_, uuid] = hd Regex.scan(~r/.+\/([\w-]+)$/, note_activity.data["object"]["id"])
+    url = "/objects/#{uuid}"
+
+    conn = conn
+    |> get(url)
+
+    assert response(conn, 200)
+  end
 end