示例#1
0
        public void RemoveByTitleTest()
        {
            // Arrange.
            var movies        = PopulateMovies();
            var shows         = new Shows();
            var showsExpected = new Shows();
            var show1         = new Show(1, Convert.ToDateTime("2017-12-12 12:00"), 120, 15, movies.Items[1]);

            shows.Items.Add(1, show1);
            showsExpected.Items.Add(1, show1);

            // Act.
            shows.Remove(movies.Items[1].Title);
            showsExpected.Items.Remove(1);

            // Assert.
            var expected = true;
            var actual   = showsExpected.Equals(shows);

            Assert.AreEqual(expected, actual);
        }