Esempio n. 1
0
        public void TurnsRightAndTurnsLeft_ShouldGoToInitialRotation()
        {
            var machine = new LawnMowingMachine(10, 10, 10, 10);

            for (int i = 0; i < 4; i++)
            {
                var rotation = machine.Rotation;
                machine.TrunLeft();
                machine.TurnRight();
                Assert.That(machine.Rotation, Is.EqualTo(rotation));

                machine.TurnRight();
            }
        }
Esempio n. 2
0
        public void IsCreatedWithValidParameters_OrientationSHouldBeNorth()
        {
            var machine = new LawnMowingMachine(10, 10, 0, 0);

            Assert.That(machine.Rotation, Is.EqualTo(Rotation.North));
        }