diff options
author | Egor Kislitsyn <egor@kislitsyn.com> | 2020-01-22 21:18:27 +0400 |
---|---|---|
committer | Egor Kislitsyn <egor@kislitsyn.com> | 2020-01-22 21:18:27 +0400 |
commit | 5c842e3b680708bedf13a63427e5e853e0184219 (patch) | |
tree | ebd6332b1d3257eb582d8c89e368e730b3f5ffac /test/web/mastodon_api/controllers/status_controller_test.exs | |
parent | b6f5b326e7b7b7e209a436190d28ac2a165cb057 (diff) | |
parent | 15db18af691f91ae7c834aa65f4b4d11d1c32d4c (diff) | |
download | pleroma-5c842e3b680708bedf13a63427e5e853e0184219.tar.gz pleroma-5c842e3b680708bedf13a63427e5e853e0184219.zip |
Merge branch 'develop' into feature/new-registrations-digest
Diffstat (limited to 'test/web/mastodon_api/controllers/status_controller_test.exs')
-rw-r--r-- | test/web/mastodon_api/controllers/status_controller_test.exs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test/web/mastodon_api/controllers/status_controller_test.exs b/test/web/mastodon_api/controllers/status_controller_test.exs index 307221c5d..b03b4b344 100644 --- a/test/web/mastodon_api/controllers/status_controller_test.exs +++ b/test/web/mastodon_api/controllers/status_controller_test.exs @@ -638,6 +638,13 @@ defmodule Pleroma.Web.MastodonAPI.StatusControllerTest do assert to_string(activity.id) == id end + test "favoriting twice will just return 200", %{conn: conn} do + activity = insert(:note_activity) + + post(conn, "/api/v1/statuses/#{activity.id}/favourite") + assert post(conn, "/api/v1/statuses/#{activity.id}/favourite") |> json_response(200) + end + test "returns 400 error for a wrong id", %{conn: conn} do conn = post(conn, "/api/v1/statuses/1/favourite") |