diff options
author | Egor Kislitsyn <egor@kislitsyn.com> | 2019-09-14 19:31:20 +0700 |
---|---|---|
committer | Egor Kislitsyn <egor@kislitsyn.com> | 2019-09-14 19:31:20 +0700 |
commit | b870ae08fd19acd7c40e4353e657e6a1ed1b34c5 (patch) | |
tree | 364f5d064d3f76748e346c2c0ae25a375cddca08 | |
parent | 4264c4b7e5c53073c3fd586c4d535952f8e18795 (diff) | |
download | pleroma-b870ae08fd19acd7c40e4353e657e6a1ed1b34c5.tar.gz |
Fix `Activity.all_by_actor_and_id/2` test
-rw-r--r-- | test/activity_test.exs | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/test/activity_test.exs b/test/activity_test.exs index f9f789a76..275cab81e 100644 --- a/test/activity_test.exs +++ b/test/activity_test.exs @@ -213,7 +213,11 @@ defmodule Pleroma.ActivityTest do assert [] == Activity.all_by_actor_and_id(user, []) - assert [%Activity{id: ^id2}, %Activity{id: ^id1}] = - Activity.all_by_actor_and_id(user.ap_id, [id1, id2]) + activities = + user.ap_id + |> Activity.all_by_actor_and_id([id1, id2]) + |> Enum.sort(&(&1.id < &2.id)) + + assert [%Activity{id: ^id1}, %Activity{id: ^id2}] = activities end end |