public void SeatsAvailableGetsSet() { var showingsController = new ShowingsController(b); var theshowing = new Showing { Movie = null, Price = 10, ScreenNumber = 10, Time = new DateTime(), TotalSeats = 100 }; var showing = showingsController.Add(theshowing); var retrieved = showingsController.Get(showing); retrieved.AvailableSeats.ShouldEqual(theshowing.TotalSeats); }
public void ShowingCanBeLookedUp() { var showingsController = new ShowingsController(b); var theshowing = new Showing { Movie = null, Price = 10, ScreenNumber = 10, Time = new DateTime(), TotalSeats = 100 }; int showing = showingsController.Add(theshowing); var retrieved = showingsController.Get(showing); retrieved.MovieId.ShouldEqual(theshowing.MovieId); retrieved.Price.ShouldEqual(theshowing.Price); retrieved.ScreenNumber.ShouldEqual(theshowing.ScreenNumber); retrieved.Time.ShouldEqual(theshowing.Time); retrieved.TotalSeats.ShouldEqual(theshowing.TotalSeats); }