diff options
author | Ivan Tashkinov <ivantashkinov@gmail.com> | 2020-04-13 09:16:51 +0300 |
---|---|---|
committer | Ivan Tashkinov <ivantashkinov@gmail.com> | 2020-04-13 09:16:51 +0300 |
commit | a21baf89d874823137cc49052cfe8da769ac0748 (patch) | |
tree | 20ed514fe2b13beebf0221d844745252f7604c02 /test/web/pleroma_api/controllers/pleroma_api_controller_test.exs | |
parent | dc2637c18880160286f50505b1140a58fdfdf7d1 (diff) | |
parent | 7ee35eb9a6a55ef610eb02a04a33f67e5921cff3 (diff) | |
download | pleroma-a21baf89d874823137cc49052cfe8da769ac0748.tar.gz pleroma-a21baf89d874823137cc49052cfe8da769ac0748.zip |
Merge remote-tracking branch 'remotes/origin/develop' into output-of-relationships-in-statuses
Diffstat (limited to 'test/web/pleroma_api/controllers/pleroma_api_controller_test.exs')
-rw-r--r-- | test/web/pleroma_api/controllers/pleroma_api_controller_test.exs | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/test/web/pleroma_api/controllers/pleroma_api_controller_test.exs b/test/web/pleroma_api/controllers/pleroma_api_controller_test.exs index 32250f06f..8bf7eb3be 100644 --- a/test/web/pleroma_api/controllers/pleroma_api_controller_test.exs +++ b/test/web/pleroma_api/controllers/pleroma_api_controller_test.exs @@ -169,6 +169,23 @@ defmodule Pleroma.Web.PleromaAPI.PleromaAPIControllerTest do id_one = activity.id id_two = activity_two.id assert [%{"id" => ^id_one}, %{"id" => ^id_two}] = result + + {:ok, %{id: id_three}} = + CommonAPI.post(other_user, %{ + "status" => "Bye!", + "in_reply_to_status_id" => activity.id, + "in_reply_to_conversation_id" => participation.id + }) + + assert [%{"id" => ^id_two}, %{"id" => ^id_three}] = + conn + |> get("/api/v1/pleroma/conversations/#{participation.id}/statuses?limit=2") + |> json_response(:ok) + + assert [%{"id" => ^id_three}] = + conn + |> get("/api/v1/pleroma/conversations/#{participation.id}/statuses?min_id=#{id_two}") + |> json_response(:ok) end test "PATCH /api/v1/pleroma/conversations/:id" do |