Ejemplo n.º 1
0
        public void MockCanEditDvd()
        {
            var    repo         = new DvdRepositoryMock();
            int    dvdId        = 2;
            string title        = "An edited movie";
            int    releaseYear  = 1999;
            string directorName = "Jacob";
            string ratingName   = "PG";
            string notes        = "A note";

            repo.Edit(dvdId, title, releaseYear, directorName, ratingName, notes);

            var test      = repo.GetAllDvd();
            var editedDvd = repo.GetById(2);

            Assert.AreEqual(2, editedDvd.DvdId);
            Assert.AreEqual("An edited movie", editedDvd.Title);
            Assert.AreEqual(1999, editedDvd.ReleaseYear);
            Assert.AreEqual("Jacob", editedDvd.Director);
            Assert.AreEqual("PG", editedDvd.Rating);
        }