mirror of
https://git.pleroma.social/pleroma/pleroma.git
synced 2024-11-14 04:52:17 +00:00
Fix pleroma.user rm mix task test
This is not the place to be validating deletes are federated
This commit is contained in:
parent
7d4dc95892
commit
aefd79be7e
1 changed files with 5 additions and 9 deletions
|
@ -100,17 +100,13 @@ defmodule Mix.Tasks.Pleroma.UserTest do
|
|||
clear_config([:instance, :federating], true)
|
||||
user = insert(:user)
|
||||
|
||||
with_mock Pleroma.Web.Federator,
|
||||
publish: fn _ -> nil end do
|
||||
Mix.Tasks.Pleroma.User.run(["rm", user.nickname])
|
||||
ObanHelpers.perform_all()
|
||||
Mix.Tasks.Pleroma.User.run(["rm", user.nickname])
|
||||
|
||||
assert_received {:mix_shell, :info, [message]}
|
||||
assert message =~ " deleted"
|
||||
assert %{is_active: false} = User.get_by_nickname(user.nickname)
|
||||
assert [{:ok, job_result}] = ObanHelpers.perform_all()
|
||||
|
||||
assert called(Pleroma.Web.Federator.publish(:_))
|
||||
end
|
||||
assert_received {:mix_shell, :info, [message]}
|
||||
assert message =~ " deleted"
|
||||
assert %{is_active: false} = User.get_by_nickname(user.nickname)
|
||||
end
|
||||
|
||||
test "a remote user's create activity is deleted when the object has been pruned" do
|
||||
|
|
Loading…
Reference in a new issue