forked from AkkomaGang/akkoma
Fix Activity.all_by_ids_with_object/1
test
This commit is contained in:
parent
d8b76c79f2
commit
3d12e05f43
1 changed files with 6 additions and 2 deletions
|
@ -178,7 +178,11 @@ test "all_by_ids_with_object/1" do
|
||||||
%{id: id1} = insert(:note_activity)
|
%{id: id1} = insert(:note_activity)
|
||||||
%{id: id2} = insert(:note_activity)
|
%{id: id2} = insert(:note_activity)
|
||||||
|
|
||||||
assert [%{id: ^id1, object: %Object{}}, %{id: ^id2, object: %Object{}}] =
|
activities =
|
||||||
Activity.all_by_ids_with_object([id1, id2])
|
[id1, id2]
|
||||||
|
|> Activity.all_by_ids_with_object()
|
||||||
|
|> Enum.sort(&(&1.id < &2.id))
|
||||||
|
|
||||||
|
assert [%{id: ^id1, object: %Object{}}, %{id: ^id2, object: %Object{}}] = activities
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue