Add an endpoint to get multiple statuses by IDs

This commit is contained in:
Egor Kislitsyn 2019-09-03 16:23:03 +07:00
commit b40b10b53d
7 changed files with 53 additions and 0 deletions

View file

@ -173,4 +173,12 @@ defmodule Pleroma.ActivityTest do
|> where([a], a.activity_id == ^activity.id)
|> Repo.one!()
end
test "all_by_ids_with_object/1" do
%{id: id1} = insert(:note_activity)
%{id: id2} = insert(:note_activity)
assert [%{id: ^id1, object: %Object{}}, %{id: ^id2, object: %Object{}}] =
Activity.all_by_ids_with_object([id1, id2])
end
end