summaryrefslogtreecommitdiff
path: root/test/activity_test.exs
diff options
context:
space:
mode:
authorIvan Tashkinov <ivantashkinov@gmail.com>2020-02-13 21:55:47 +0300
committerIvan Tashkinov <ivantashkinov@gmail.com>2020-02-13 21:55:47 +0300
commit4f8c3462a8821ffcf83f8b65edf48e55eff7080c (patch)
treea532e6761adde4e23f2b7e980f76e4c6f5b08148 /test/activity_test.exs
parent9906c6fb6fb0e2ebb36fa91fae94828bcc02ef27 (diff)
downloadpleroma-4f8c3462a8821ffcf83f8b65edf48e55eff7080c.tar.gz
pleroma-4f8c3462a8821ffcf83f8b65edf48e55eff7080c.zip
Tweaks to `clear_config` calls in tests in order to prevent side effects on config during test suite execution.
Diffstat (limited to 'test/activity_test.exs')
-rw-r--r--test/activity_test.exs5
1 files changed, 2 insertions, 3 deletions
diff --git a/test/activity_test.exs b/test/activity_test.exs
index e7ea2bd5e..8aeece96d 100644
--- a/test/activity_test.exs
+++ b/test/activity_test.exs
@@ -138,6 +138,8 @@ defmodule Pleroma.ActivityTest do
}
end
+ clear_config([:instance, :limit_to_local_content])
+
test "finds utf8 text in statuses", %{
japanese_activity: japanese_activity,
user: user
@@ -165,7 +167,6 @@ defmodule Pleroma.ActivityTest do
%{local_activity: local_activity} do
Pleroma.Config.put([:instance, :limit_to_local_content], :all)
assert [^local_activity] = Activity.search(nil, "find me")
- Pleroma.Config.put([:instance, :limit_to_local_content], :unauthenticated)
end
test "find all statuses for unauthenticated users when `limit_to_local_content` is `false`",
@@ -178,8 +179,6 @@ defmodule Pleroma.ActivityTest do
activities = Enum.sort_by(Activity.search(nil, "find me"), & &1.id)
assert [^local_activity, ^remote_activity] = activities
-
- Pleroma.Config.put([:instance, :limit_to_local_content], :unauthenticated)
end
end