summaryrefslogtreecommitdiff
path: root/test/pleroma/conversation/participation_test.exs
diff options
context:
space:
mode:
Diffstat (limited to 'test/pleroma/conversation/participation_test.exs')
-rw-r--r--test/pleroma/conversation/participation_test.exs12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/pleroma/conversation/participation_test.exs b/test/pleroma/conversation/participation_test.exs
index 8b039cd78..a25e17c95 100644
--- a/test/pleroma/conversation/participation_test.exs
+++ b/test/pleroma/conversation/participation_test.exs
@@ -359,4 +359,16 @@ defmodule Pleroma.Conversation.ParticipationTest do
assert Participation.unread_count(blocked) == 1
end
end
+
+ test "deletes a conversation" do
+ user = insert(:user)
+ other_user = insert(:user)
+
+ {:ok, _activity} =
+ CommonAPI.post(user, %{status: "Hey @#{other_user.nickname}.", visibility: "direct"})
+
+ assert [participation] = Participation.for_user(other_user)
+ assert {:ok, _} = Participation.delete(participation)
+ assert [] == Participation.for_user(other_user)
+ end
end