projects
/
akkoma
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Credo fixes.
[akkoma]
/
test
/
object_test.exs
diff --git
a/test/object_test.exs
b/test/object_test.exs
index 5690bedece2261874a39adc5bd9322394e49e3e7..198d3b1cf1ac969016e0ca5effc2f0000ee9210b 100644
(file)
--- a/
test/object_test.exs
+++ b/
test/object_test.exs
@@
-1,5
+1,5
@@
# 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.ObjectTest do
# SPDX-License-Identifier: AGPL-3.0-only
defmodule Pleroma.ObjectTest do
@@
-74,7
+74,8
@@
defmodule Pleroma.ObjectTest do
end
describe "delete attachments" do
end
describe "delete attachments" do
- clear_config([Pleroma.Upload])
+ setup do: clear_config([Pleroma.Upload])
+ setup do: clear_config([:instance, :cleanup_attachments])
test "Disabled via config" do
Pleroma.Config.put([Pleroma.Upload, :uploader], Pleroma.Uploaders.Local)
test "Disabled via config" do
Pleroma.Config.put([Pleroma.Upload, :uploader], Pleroma.Uploaders.Local)
@@
-379,7
+380,8
@@
defmodule Pleroma.ObjectTest do
user = insert(:user)
activity = Activity.get_create_by_object_ap_id(object.data["id"])
user = insert(:user)
activity = Activity.get_create_by_object_ap_id(object.data["id"])
- {:ok, _activity, object} = CommonAPI.favorite(activity.id, user)
+ {:ok, activity} = CommonAPI.favorite(user, activity.id)
+ object = Object.get_by_ap_id(activity.data["object"])
assert object.data["like_count"] == 1
assert object.data["like_count"] == 1