X-Git-Url: https://git.squeep.com/?a=blobdiff_plain;f=test%2Fplugs%2Fuploaded_media_plug_test.exs;h=20b13dfac8cb348d4450dc03c4a1dd84ba2d54ca;hb=cc196e2cd57966889021342405ebc8fd0763e83a;hp=414cf91864dcf827786fe8e0a3557c37db21558c;hpb=e2fe796c63f9df18d30810ad9daa1e7027da120f;p=akkoma
diff --git a/test/plugs/uploaded_media_plug_test.exs b/test/plugs/uploaded_media_plug_test.exs
index 414cf9186..20b13dfac 100644
--- a/test/plugs/uploaded_media_plug_test.exs
+++ b/test/plugs/uploaded_media_plug_test.exs
@@ -1,12 +1,13 @@
# Pleroma: A lightweight social networking server
-# Copyright © 2017-2018 Pleroma Authors
+# Copyright © 2017-2020 Pleroma Authors
# 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{
@@ -20,6 +21,8 @@ defmodule Pleroma.Web.UploadedMediaPlugTest do
[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