Ejemplo n.º 1
0
        public void TestGetSingleMovie()
        {
            IMoviefileService MoviefileService = new MoviefileService(_movieRepository.Object, _actorRepository.Object);
            var Movie = MoviefileService.GetSingleMovie(Guid.NewGuid());

            Assert.IsInstanceOfType(Movie, typeof(Moviefile.services.Model.Movie));
            Assert.AreEqual("Image1", Movie.CoverImage);
        }
Ejemplo n.º 2
0
        public void TestGetMovieCollection()
        {
            IMoviefileService MoviefileService = new MoviefileService(_movieRepository.Object, _actorRepository.Object);
            var Movies = MoviefileService.GetMovieCollection(Guid.NewGuid());

            Assert.IsInstanceOfType(Movies, typeof(IList <MovieDto>));
            Assert.AreEqual(2, Movies.Count);
        }
Ejemplo n.º 3
0
        public void TestGetActorCollection()
        {
            IMoviefileService MoviefileService = new MoviefileService(_movieRepository.Object, _actorRepository.Object);
            var Actors = MoviefileService.GetActorCollection(Guid.NewGuid());

            Assert.IsInstanceOfType(Actors, typeof(IList <ActorDto>));
            Assert.AreEqual(1, Actors.Count);
        }
Ejemplo n.º 4
0
        public void TestGetSingleActor()
        {
            IMoviefileService MoviefileService = new MoviefileService(_movieRepository.Object, _actorRepository.Object);
            var Actor = MoviefileService.GetSingleActor(Guid.NewGuid());

            Assert.IsInstanceOfType(Actor, typeof(Moviefile.services.Model.Actor));
            Assert.AreEqual("John Smith", Actor.Name);
        }