예제 #1
0
        public void IdFilter_ConstructWithSingleId()
        {
            var filter = new IdFilter(dummyFixture.Id);

            Assert.False(filter.IsEmpty);
            Assert.That(filter.Match(dummyFixture));
            Assert.False(filter.Match(anotherFixture));
        }
예제 #2
0
        public void IdFilter_ConstructWithMultipleIds()
        {
            var filter = new IdFilter(new string[] { dummyFixture.Id, anotherFixture.Id });

            Assert.False(filter.IsEmpty);
            Assert.That(filter.Match(dummyFixture));
            Assert.That(filter.Match(anotherFixture));
            Assert.False(filter.Match(yetAnotherFixture));
        }
예제 #3
0
        public void IdFilter_AddIds()
        {
            var filter = new IdFilter();

            filter.Add(dummyFixture.Id);
            filter.Add(anotherFixture.Id);

            Assert.False(filter.IsEmpty);
            Assert.That(filter.Match(dummyFixture));
            Assert.That(filter.Match(anotherFixture));
            Assert.False(filter.Match(yetAnotherFixture));
        }