summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormarcin mikołajczak <git@mkljczk.pl>2022-01-23 12:50:34 +0100
committermarcin mikołajczak <git@mkljczk.pl>2022-01-23 13:03:00 +0100
commit75c4fefb1c3a8e4ce21661cbd634c608365354ba (patch)
tree29d8f1b6a07bccae8ef30a6a3a9dc1607cff4f28
parent1dba3bc4dcae9edf3df73b5855b010c9ba451fce (diff)
Add a test
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
-rw-r--r--test/pleroma/user_test.exs11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/pleroma/user_test.exs b/test/pleroma/user_test.exs
index 0345a9290..a5a9021f6 100644
--- a/test/pleroma/user_test.exs
+++ b/test/pleroma/user_test.exs
@@ -2084,6 +2084,17 @@ defmodule Pleroma.UserTest do
assert user.ap_id in ap_ids
assert user_two.ap_id in ap_ids
end
+
+ test "it returns a list of AP ids in the same order" do
+ user = insert(:user)
+ user_two = insert(:user)
+ user_three = insert(:user)
+
+ ap_ids =
+ User.get_ap_ids_by_nicknames([user.nickname, user_three.nickname, user_two.nickname])
+
+ assert [user.ap_id, user_three.ap_id, user_two.ap_id] == ap_ids
+ end
end
describe "sync followers count" do