Beispiel #1
0
        public ElectStateContextMock()
        {
            StateContextValue   = new StateContextMock();
            CandidateStateValue = new Mock <IState>().Object;
            CurrentStateValue   = "OldState";

            _context = new Lazy <ElectStateContext>(
                () => new ElectStateContext(
                    StateContextValue.Object,
                    CandidateStateValue,
                    CurrentStateValue));
        }
Beispiel #2
0
        public ApplyStateContextMock()
        {
            StateContextValue = new StateContextMock();
            NewStateValue     = new Mock <IState>().Object;
            OldStateValue     = null;

            _context = new Lazy <ApplyStateContext>(
                () => new ApplyStateContext(
                    StateContextValue.Object,
                    NewStateValue,
                    OldStateValue));
        }
        public ElectStateContextMock()
        {
            StateContextValue = new StateContextMock();
            CandidateStateValue = new Mock<IState>().Object;
            CurrentStateValue = "OldState";

            _context = new Lazy<ElectStateContext>(
                () => new ElectStateContext(
                    StateContextValue.Object, 
                    CandidateStateValue,
                    CurrentStateValue));
        }
        public ApplyStateContextMock()
        {
            StateContextValue = new StateContextMock();
            NewStateValue = new Mock<IState>().Object;
            OldStateValue = null;

            _context = new Lazy<ApplyStateContext>(
                () => new ApplyStateContext(
                    StateContextValue.Object,
                    NewStateValue,
                    OldStateValue));
        }
Beispiel #5
0
        public ApplyStateContextMock()
        {
            StateContextValue    = new StateContextMock();
            NewStateValue        = new Mock <IState>().Object;
            OldStateValue        = null;
            TraversedStatesValue = Enumerable.Empty <IState>();

            _context = new Lazy <ApplyStateContext>(
                () => new ApplyStateContext(
                    StateContextValue.Object,
                    NewStateValue,
                    OldStateValue,
                    TraversedStatesValue));
        }
        public ApplyStateContextMock()
        {
            StateContextValue = new StateContextMock();
            NewStateValue = new Mock<IState>().Object;
            OldStateValue = null;
            TraversedStatesValue = Enumerable.Empty<IState>();

            _context = new Lazy<ApplyStateContext>(
                () => new ApplyStateContext(
                    StateContextValue.Object,
                    NewStateValue,
                    OldStateValue,
                    TraversedStatesValue));
        }