Exemplo n.º 1
0
        public void GetNewNotificationsFor_NotificationIsRead_ShouldNotBeReturned()
        {
            var notification = Notification.GigCanceled(new Gig());
            var user         = new ApplicationUser {
                Id = _userId
            };
            var userNotification = new UserNotification(user, notification);

            userNotification.Read();

            _mockNotifications.SetSource(new[] { userNotification });

            var notifications = _repository.GetNewNotifications(user.Id);

            notifications.Should().BeEmpty();
        }