Esempio n. 1
0
        public void GetEvents()
        {
            //Arrange
            var recentEventFilter = new DTO.RecentEventFilter()
            {
                ContributedBy    = new string[] { fixtures.identityId.ToString() },
                ContributedAfter = DateTime.Now.AddYears(-1)
            };

            //Act
            var result = fixtures.recentQueryService.GetEvents(recentEventFilter);

            //Assert
            result.Should().NotBeEmpty();
            result.Count().Should().BeGreaterOrEqualTo(1);
        }
Esempio n. 2
0
        public List <DTO.RecentEvent> GetEvents(DTO.RecentEventFilter filter)
        {
            var query = ApplyFilter(filter, UnitOfWork.GetEntityQuery <RecentEvent>().OrderByDescending(e => e.DateContributed));

            return(query.AsListOf <DTO.RecentEvent>());
        }