diff options
author | Sergey Suprunenko <suprunenko.s@gmail.com> | 2020-08-15 15:27:41 +0200 |
---|---|---|
committer | Sergey Suprunenko <suprunenko.s@gmail.com> | 2020-08-15 15:27:41 +0200 |
commit | 0865f36965f1583085af3a424dbbc89de724fd33 (patch) | |
tree | f009becfbcd1e4a698d07c5d66e71084220f6295 /test/notification_test.exs | |
parent | ec242b470654e5e66e3d3a36e8d7563e15b08016 (diff) | |
download | pleroma-0865f36965f1583085af3a424dbbc89de724fd33.tar.gz pleroma-0865f36965f1583085af3a424dbbc89de724fd33.zip |
Mark notifications about statuses from muted users as read automatically
Diffstat (limited to 'test/notification_test.exs')
-rw-r--r-- | test/notification_test.exs | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/test/notification_test.exs b/test/notification_test.exs index 8243cfd34..93f4761da 100644 --- a/test/notification_test.exs +++ b/test/notification_test.exs @@ -217,7 +217,10 @@ defmodule Pleroma.NotificationTest do muter = Repo.get(User, muter.id) {:ok, activity} = CommonAPI.post(muted, %{status: "Hi @#{muter.nickname}"}) - assert Notification.create_notification(activity, muter) + notification = Notification.create_notification(activity, muter) + + assert notification.id + assert notification.seen end test "notification created if user is muted without notifications" do @@ -1012,6 +1015,7 @@ defmodule Pleroma.NotificationTest do [notification] = Notification.for_user(user) assert notification.activity.object + assert notification.seen end test "it doesn't return notifications for muted user with notifications", %{user: user} do |