예제 #1
0
        public void SetUp()
        {
            pureDataFacadeMock_         = Substitute.For <IPureDataFacade>();
            controllerStateFactoryMock_ = Substitute.For <IControllerStateFactory>();
            controllerStateFactoryMock_.CreateCarrierState(pureDataFacadeMock_).Returns(carrierStateMock_);
            controllerStateFactoryMock_.CreateModulatorState(pureDataFacadeMock_).Returns(modulatorStateMock_);

            stateAssigner_ = new StateAssigner(pureDataFacadeMock_, controllerStateFactoryMock_);
        }
예제 #2
0
        public void CreateCarrierState()
        {
            var carrierState = ControllerStateFactory_.CreateCarrierState(Arg.Any <IPureDataFacade>());

            Assert.True(carrierState != null);
            Assert.DoesNotThrow(() =>
            {
                var unused = (CarrierState)carrierState;
            });
        }