projects
/
akkoma
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Update clear_config macro
[akkoma]
/
test
/
upload
/
filter
/
mogrify_test.exs
diff --git
a/test/upload/filter/mogrify_test.exs
b/test/upload/filter/mogrify_test.exs
index 210320d303eb70657a66a365e55f444c536edf11..62ca304877ca3f02a73229eb761493403410b76e 100644
(file)
--- a/
test/upload/filter/mogrify_test.exs
+++ b/
test/upload/filter/mogrify_test.exs
@@
-1,26
+1,22
@@
# Pleroma: A lightweight social networking server
# Pleroma: A lightweight social networking server
-# Copyright © 2017-20
19
Pleroma Authors <https://pleroma.social/>
+# Copyright © 2017-20
20
Pleroma Authors <https://pleroma.social/>
# SPDX-License-Identifier: AGPL-3.0-only
defmodule Pleroma.Upload.Filter.MogrifyTest do
use Pleroma.DataCase
import Mock
# SPDX-License-Identifier: AGPL-3.0-only
defmodule Pleroma.Upload.Filter.MogrifyTest do
use Pleroma.DataCase
import Mock
- alias Pleroma.Config
- alias Pleroma.Upload
alias Pleroma.Upload.Filter
alias Pleroma.Upload.Filter
- clear_config([Filter.Mogrify, :args])
-
test "apply mogrify filter" do
test "apply mogrify filter" do
-
Config.put([Filter.Mogrify, :args],
[{"tint", "40"}])
+
clear_config(Filter.Mogrify, args:
[{"tint", "40"}])
File.cp!(
"test/fixtures/image.jpg",
"test/fixtures/image_tmp.jpg"
)
File.cp!(
"test/fixtures/image.jpg",
"test/fixtures/image_tmp.jpg"
)
- upload = %Upload{
+ upload = %
Pleroma.
Upload{
name: "an… image.jpg",
content_type: "image/jpg",
path: Path.absname("test/fixtures/image_tmp.jpg"),
name: "an… image.jpg",
content_type: "image/jpg",
path: Path.absname("test/fixtures/image_tmp.jpg"),