コード例 #1
0
        public void CorrectInitialization()
        {
            // Arrange:
            string      Ttile = "Best Title";
            string      header = "Best Header";
            AgendaPoint firstPoint, secondPoint;
            Agenda      agenda;
            int         id = 1;

            // Act:
            firstPoint  = new AgendaPoint(header);
            secondPoint = new AgendaPoint(id, header);
            agenda      = new Agenda(Ttile, firstPoint);
            agenda.AddAgenda(secondPoint);
            agenda.ConclueCurrentAgendaPoint();

            // Assert:
            Assert.AreEqual(header, firstPoint.Header);
            Assert.AreEqual(Ttile, agenda.Title);
            Assert.AreEqual(0, firstPoint.Id);
            Assert.AreEqual(id, secondPoint.Id);
            Assert.AreEqual(secondPoint, agenda.CurrentAgendaPoint);
        }