SortByEnd() public méthode

public SortByEnd ( ListSortDirection sortDirection = ListSortDirection.Ascending ) : void
sortDirection ListSortDirection
Résultat void
        public void SortByEndTest()
        {
            DateTime now = ClockProxy.Clock.Now;
            SchoolDay schoolDay = new SchoolDay( now );
            TimePeriodCollection timePeriods = new TimePeriodCollection();

            timePeriods.AddAll( schoolDay );

            timePeriods.SortByEnd();

            Assert.AreEqual( timePeriods[ 0 ], schoolDay.Lesson4 );
            Assert.AreEqual( timePeriods[ 1 ], schoolDay.Break3 );
            Assert.AreEqual( timePeriods[ 2 ], schoolDay.Lesson3 );
            Assert.AreEqual( timePeriods[ 3 ], schoolDay.Break2 );
            Assert.AreEqual( timePeriods[ 4 ], schoolDay.Lesson2 );
            Assert.AreEqual( timePeriods[ 5 ], schoolDay.Break1 );
            Assert.AreEqual( timePeriods[ 6 ], schoolDay.Lesson1 );
        }