예제 #1
0
        public void ShouldInvokedNextAction()
        {
            //Arrange
            FakeDifficultySelectionAction nextAction = new FakeDifficultySelectionAction.Builder().Act(null).Build();
            DifficultySelectionAction     subject    = new DifficultySelectionAction(nextAction);

            //Act
            subject.Response("");

            //Assert
            nextAction.AssertActInvoked();
        }
예제 #2
0
        public void ShouldHaveExpectedOrder()
        {
            //Arrange
            ChainValidation chainValidation = new ChainValidation()
                                              .Add <EasyDifficultySelectionAction>()
                                              .Add <MediumDifficultySelectionAction>()
                                              .Add <HardDifficultySelectionAction>();

            //Act
            DifficultySelectionAction subject = new DifficultySelectionAction();

            //Assert
            chainValidation.AssertExpectedChain(subject);
        }