public async Task Paged_Results()
        {
            using var factory = new AppDbContextFactory();
            using var context = factory.CreateContext(true);

            // Arrange
            var sut     = new GetContactsHandler(_logger, context);
            var contact = context.Contacts.First();
            var cmd     = new GetContactsQuery {
                Skip = 1, Take = 1
            };

            // Act
            var results = await sut.Handle(cmd);

            // Assert
            Assert.DoesNotContain(results, r => r.Name == contact.Name);
            Assert.True(results.Count() == 1);
        }
        public async Task Sorted_Results()
        {
            using var factory = new AppDbContextFactory();
            using var context = factory.CreateContext(true);

            // Arrange
            var sut     = new GetContactsHandler(_logger, context);
            var contact = context.Contacts.First();
            var cmd     = new GetContactsQuery {
                SortBy = nameof(contact.Name), Ascending = false
            };

            // Act
            var results = await sut.Handle(cmd);

            // Assert
            Assert.True(results.Last().Name == contact.Name);
            Assert.True(results.Count() == 2);
        }