projects
/
akkoma
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
update musl
[akkoma]
/
test
/
pleroma
/
uploaders
/
s3_test.exs
diff --git
a/test/pleroma/uploaders/s3_test.exs
b/test/pleroma/uploaders/s3_test.exs
index 9910525962c505dc68a49df81a0c051020141db7..2711e2c8df5911c165cdd58ca6a75f0d2bedcd97 100644
(file)
--- a/
test/pleroma/uploaders/s3_test.exs
+++ b/
test/pleroma/uploaders/s3_test.exs
@@
-1,11
+1,10
@@
# Pleroma: A lightweight social networking server
# Pleroma: A lightweight social networking server
-# Copyright © 2017-202
0
Pleroma Authors <https://pleroma.social/>
+# Copyright © 2017-202
1
Pleroma Authors <https://pleroma.social/>
# SPDX-License-Identifier: AGPL-3.0-only
defmodule Pleroma.Uploaders.S3Test do
use Pleroma.DataCase
# SPDX-License-Identifier: AGPL-3.0-only
defmodule Pleroma.Uploaders.S3Test do
use Pleroma.DataCase
- alias Pleroma.Config
alias Pleroma.Uploaders.S3
import Mock
alias Pleroma.Uploaders.S3
import Mock
@@
-27,13
+26,13
@@
defmodule Pleroma.Uploaders.S3Test do
end
test "it returns path without bucket when truncated_namespace set to ''" do
end
test "it returns path without bucket when truncated_namespace set to ''" do
-
Config.put
([Pleroma.Uploaders.S3],
+
clear_config
([Pleroma.Uploaders.S3],
bucket: "test_bucket",
bucket_namespace: "myaccount",
truncated_namespace: ""
)
bucket: "test_bucket",
bucket_namespace: "myaccount",
truncated_namespace: ""
)
-
Config.put
([Pleroma.Upload, :base_url], "https://s3.amazonaws.com")
+
clear_config
([Pleroma.Upload, :base_url], "https://s3.amazonaws.com")
assert S3.get_file("test_image.jpg") == {
:ok,
assert S3.get_file("test_image.jpg") == {
:ok,
@@
-42,7
+41,7
@@
defmodule Pleroma.Uploaders.S3Test do
end
test "it returns path with bucket namespace when namespace is set" do
end
test "it returns path with bucket namespace when namespace is set" do
-
Config.put
([Pleroma.Uploaders.S3],
+
clear_config
([Pleroma.Uploaders.S3],
bucket: "test_bucket",
bucket_namespace: "family"
)
bucket: "test_bucket",
bucket_namespace: "family"
)