# Pleroma: A lightweight social networking server
-# Copyright © 2017-2018 Pleroma Authors <https://pleroma.social/>
+# Copyright © 2017-2020 Pleroma Authors <https://pleroma.social/>
# SPDX-License-Identifier: AGPL-3.0-only
defmodule Pleroma.Web.UploadedMediaPlugTest do
use Pleroma.Web.ConnCase
alias Pleroma.Upload
- setup_all do
+ defp upload_file(context) do
+ Pleroma.DataCase.ensure_local_uploader(context)
File.cp!("test/fixtures/image.jpg", "test/fixtures/image_tmp.jpg")
file = %Plug.Upload{
[attachment_url: attachment_url]
end
+ setup_all :upload_file
+
test "does not send Content-Disposition header when name param is not set", %{
attachment_url: attachment_url
} do