public void GetAllStudiosTest() { var repo = new DVDMockRepo(); var result = repo.GetAllStudios(); Assert.AreEqual(result.Count, 3); }
public void GetAllMPAATest() { var repo = new DVDMockRepo(); var result = repo.GetAllMPAA(); Assert.AreEqual(result.Count, 5); }
public void RemoveDVDTest() { var repo = new DVDMockRepo(); int dvdId = 1; repo.RemoveDVD(dvdId); Assert.AreEqual(DVDMockRepo._dvds.Count, 2); }
public void GetDVDByIdTest() { var repo = new DVDMockRepo(); int dvdID = 1; var result = repo.GetDVDById(dvdID); Assert.AreEqual(result.Title, "Talladega Nights"); }
public void GetActorDetailsTest() { var repo = new DVDMockRepo(); int dvdID = 1; var result = repo.GetActorDetails(dvdID); Assert.AreEqual(result.Count, 2); }
public void GetDVDByTitleTest() { var repo = new DVDMockRepo(); string title = "Happy Gilmore"; var result = repo.GetDVDByTitle(title); Assert.AreEqual(result.Count, 1); Assert.AreNotEqual(result[0].Title, "Happy Days"); }
public void AddDVDTest() { var repo = new DVDMockRepo(); var dvd = new DVD() { Title = "Test", ReleaseDate = new DateTime(2015, 10, 19), MPAA = "R", Director = "Mr. Test", StudioID = 1 }; int dvdId = repo.AddDVD(dvd); Assert.AreEqual(DVDMockRepo._dvds.Count, 4); Assert.AreEqual(DVDMockRepo._dvds[3].Title, "Test"); }