diff options
author | Alex Gleason <alex@alexgleason.me> | 2020-07-16 21:39:10 -0500 |
---|---|---|
committer | Alex Gleason <alex@alexgleason.me> | 2020-07-17 12:35:28 -0500 |
commit | 48f8b26c92880c0898daac3d691c61be0b891d0b (patch) | |
tree | 0cc8d85a026e9ff29250ffe95541ab5fd9c47ae5 /test/pagination_test.exs | |
parent | 3a2b2cb6f2d6ce39ae0d246649189c021c535992 (diff) | |
download | pleroma-48f8b26c92880c0898daac3d691c61be0b891d0b.tar.gz pleroma-48f8b26c92880c0898daac3d691c61be0b891d0b.zip |
OpenAPI: Add :id to follower/following endpoints, fixes #1958
Diffstat (limited to 'test/pagination_test.exs')
-rw-r--r-- | test/pagination_test.exs | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/test/pagination_test.exs b/test/pagination_test.exs index 9165427ae..e526f23e8 100644 --- a/test/pagination_test.exs +++ b/test/pagination_test.exs @@ -54,6 +54,20 @@ defmodule Pleroma.PaginationTest do assert length(paginated) == 1 end + + test "handles id gracefully", %{notes: notes} do + id = Enum.at(notes, 1).id |> Integer.to_string() + + paginated = + Pagination.fetch_paginated(Object, %{ + id: "9s99Hq44Cnv8PKBwWG", + max_id: id, + limit: 20, + offset: 0 + }) + + assert length(paginated) == 1 + end end describe "offset" do |