X-Git-Url: http://git.squeep.com/?a=blobdiff_plain;f=test%2Fnotification_test.exs;h=8db3495262a0e44e0c3cf2deef6f462d8130d650;hb=49bb0a130f93476d32d3177d7a989b7a98a063f2;hp=dcbffeafe39b16c1afdf7505fc4744cf2119ce25;hpb=228bf4d214abe3bb62c52128d3bc145e396b174d;p=akkoma diff --git a/test/notification_test.exs b/test/notification_test.exs index dcbffeafe..8db349526 100644 --- a/test/notification_test.exs +++ b/test/notification_test.exs @@ -31,6 +31,9 @@ defmodule Pleroma.NotificationTest do assert notified_ids == [other_user.id, third_user.id] assert notification.activity_id == activity.id assert other_notification.activity_id == activity.id + + assert [%Pleroma.Marker{unread_count: 2}] = + Pleroma.Marker.get_markers(other_user, ["notifications"]) end test "it creates a notification for subscribed users" do @@ -310,6 +313,13 @@ defmodule Pleroma.NotificationTest do assert n1.seen == true assert n2.seen == true assert n3.seen == false + + assert %Pleroma.Marker{unread_count: 1} = + Pleroma.Repo.get_by( + Pleroma.Marker, + user_id: other_user.id, + timeline: "notifications" + ) end end