Пример #1
0
        public void Can_Page_Results()
        {
            var spec    = new EvenNumbersSpecification();
            var results = spec.SatisfyingElementsFrom(_numbers.AsQueryable());

            Assert.That(results.Count(), Is.EqualTo(10));
        }
Пример #2
0
        public void EvenNumbersSpecification_Returns_Only_Even_Members()
        {
            var spec = new EvenNumbersSpecification();

            var results = spec.SatisfyingElementsFrom(_numbers.AsQueryable());

            foreach (var item in results)
            {
                Assert.That(item % 2 == 0);
            }
        }