diff options
author | rinpatch <rinpatch@sdf.org> | 2020-06-09 18:06:27 +0000 |
---|---|---|
committer | rinpatch <rinpatch@sdf.org> | 2020-06-09 18:06:27 +0000 |
commit | 6c90fc8e70760bf8c58bb731ce294e9eee02f430 (patch) | |
tree | bd9a1f004b07c434c1ae2a6b3701ffad52d6304a /test/notification_test.exs | |
parent | a5ccb5b0b1032b102c54d4df2e17c61423089e73 (diff) | |
parent | f05f206e13a152ccdae679e84a29633adfbba2b1 (diff) | |
download | pleroma-2.0.6.tar.gz |
Merge branch 'release/2.0.6' into 'stable'v2.0.6
Release/2.0.6
See merge request pleroma/pleroma!2632
Diffstat (limited to 'test/notification_test.exs')
-rw-r--r-- | test/notification_test.exs | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/test/notification_test.exs b/test/notification_test.exs index d04754a9d..80fa52312 100644 --- a/test/notification_test.exs +++ b/test/notification_test.exs @@ -446,8 +446,7 @@ defmodule Pleroma.NotificationTest do "status" => "hey again @#{other_user.nickname}!" }) - [n2, n1] = notifs = Notification.for_user(other_user) - assert length(notifs) == 2 + [n2, n1] = Notification.for_user(other_user) assert n2.id > n1.id @@ -456,7 +455,9 @@ defmodule Pleroma.NotificationTest do "status" => "hey yet again @#{other_user.nickname}!" }) - Notification.set_read_up_to(other_user, n2.id) + [_, read_notification] = Notification.set_read_up_to(other_user, n2.id) + + assert read_notification.activity.object [n3, n2, n1] = Notification.for_user(other_user) @@ -885,7 +886,9 @@ defmodule Pleroma.NotificationTest do {:ok, _activity} = CommonAPI.post(muted, %{"status" => "hey @#{user.nickname}"}) - assert length(Notification.for_user(user)) == 1 + [notification] = Notification.for_user(user) + + assert notification.activity.object end test "it doesn't return notifications for muted user with notifications" do |