public void FloorsShouldBeBroadcastInOrderWhenUpwardsRequestIsMade()
        {
            var lift = new LateRoomsLift(0);
            lift.FloorVisitAction = VisitFloor;

            lift.Visit(2);

            Assert.That(_floorsVisited.Count, Is.EqualTo(2));
            Assert.That(_floorsVisited[0], Is.EqualTo(1));
            Assert.That(_floorsVisited[1], Is.EqualTo(2));
        }
Example #2
0
        public void FloorsShouldBeBroadcastInOrderWhenUpwardsRequestIsMade()
        {
            var lift = new LateRoomsLift(0);

            lift.FloorVisitAction = VisitFloor;

            lift.Visit(2);

            Assert.That(_floorsVisited.Count, Is.EqualTo(2));
            Assert.That(_floorsVisited[0], Is.EqualTo(1));
            Assert.That(_floorsVisited[1], Is.EqualTo(2));
        }