Deduplicate notifications in notification model

This commit is contained in:
Mouse Reeve
2021-02-10 16:21:29 -08:00
parent d9e65aa363
commit e0cfb009e4
5 changed files with 16 additions and 12 deletions

View File

@ -30,7 +30,7 @@ class NotificationViews(TestCase):
def test_clear_notifications(self):
''' erase notifications '''
models.Notification.objects.create(
user=self.local_user, notification_type='MENTION')
user=self.local_user, notification_type='FAVORITE')
models.Notification.objects.create(
user=self.local_user, notification_type='MENTION', read=True)
self.assertEqual(models.Notification.objects.count(), 2)