예제 #1
0
        public void CanSearchOnRatingIdMock()
        {
            var repo  = new DvdRepositoryMock();
            var found = repo.Search(new DvdSearchParameter {
                RatingName = "PG-13"
            });

            Assert.AreEqual(1, found.Count());
        }
예제 #2
0
        public void CanSearchByYearMock()
        {
            var repo  = new DvdRepositoryMock();
            var found = repo.Search(new DvdSearchParameter {
                ReleaseYear = 1990
            });

            Assert.AreEqual(1, found.Count());
        }
예제 #3
0
        public void CanSearchByDirectorNameMock()
        {
            var repo  = new DvdRepositoryMock();
            var found = repo.Search(new DvdSearchParameter {
                DirectorName = "Cameron"
            });

            Assert.AreEqual(2, found.Count());
        }
예제 #4
0
        public void CanSearchByTitleMock()
        {
            var repo  = new DvdRepositoryMock();
            var found = repo.Search(new DvdSearchParameter {
                Title = "Titanic"
            });

            Assert.AreEqual(1, found.Count());
        }