aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWilliam Pitcock <nenolod@dereferenced.org>2018-07-17 03:37:26 +0000
committerWilliam Pitcock <nenolod@dereferenced.org>2018-07-17 03:40:47 +0000
commit489453c2467b12970258927015209c9895d5cf6e (patch)
tree90e288c6e843045319b16b2556332eecc64a43a3
parent99c0252314fc3391e6fae58bdad8110d0a053fb9 (diff)
downloadpleroma-489453c2467b12970258927015209c9895d5cf6e.tar.gz
tests: verify media description api support is working
-rw-r--r--test/web/mastodon_api/mastodon_api_controller_test.exs5
1 files changed, 4 insertions, 1 deletions
diff --git a/test/web/mastodon_api/mastodon_api_controller_test.exs b/test/web/mastodon_api/mastodon_api_controller_test.exs
index d1812457d..9e33c1d04 100644
--- a/test/web/mastodon_api/mastodon_api_controller_test.exs
+++ b/test/web/mastodon_api/mastodon_api_controller_test.exs
@@ -736,16 +736,19 @@ defmodule Pleroma.Web.MastodonAPI.MastodonAPIControllerTest do
filename: "an_image.jpg"
}
+ desc = "Description of the image"
+
user = insert(:user)
conn =
conn
|> assign(:user, user)
- |> post("/api/v1/media", %{"file" => file})
+ |> post("/api/v1/media", %{"file" => file, "description" => desc})
assert media = json_response(conn, 200)
assert media["type"] == "image"
+ assert media["description"] == desc
end
test "hashtag timeline", %{conn: conn} do