moveCoordY() публичный Метод

public moveCoordY ( enumIncDec _eidIncOrDec ) : void
_eidIncOrDec enumIncDec
Результат void
        public void moveCoordY_CalledWithArgIncreasing_CallsRobotmoveByYCoordinateWithPositiveSpeedValue_ReturnFalse_ExpectException()
        {
            // Setup
            IRobot irMock = MockRepository.GenerateMock<IRobot>();
            mcTestObj = new ManualController();
            mcTestObj.RobotConnection = irMock;
            mcTestObj.Speed = 50;
            irMock.Stub(t => t.moveByYCoordinate(Arg<int>.Is.Anything)).Return(false);

            // Test
            Assert.Catch(() => mcTestObj.moveCoordY(enumIncDec.MANUAL_MOVE_INC));
        }
        public void moveCoordY_CalledWithArgIncreasing_CallsRobotmoveByYCoordinateWithPositiveSpeedValue()
        {
            // Setup
            IRobot irMock = MockRepository.GenerateMock<IRobot>();
            mcTestObj = new ManualController();
            mcTestObj.RobotConnection = irMock;
            mcTestObj.Speed = 50;
            irMock.Stub(t => t.moveByYCoordinate(Arg<int>.Is.Anything)).Return(true);

            // Test
            mcTestObj.moveCoordY(enumIncDec.MANUAL_MOVE_INC);

            // Verify
            irMock.AssertWasCalled(t => t.moveByYCoordinate(mcTestObj.Speed));
        }