Ejemplo n.º 1
0
        public void Typed_events_should_carry_their_data_to_the_expression_other()
        {
            ExampleStateMachine example = new ExampleStateMachine();

            example.SubmitCommentCard(new CommentCard {
                IsComplaint = false
            });

            Assert.AreEqual(ExampleStateMachine.Completed, example.CurrentState);
        }
Ejemplo n.º 2
0
        public void Typed_events_should_carry_their_data_to_the_expression()
        {
            ExampleStateMachine example = new ExampleStateMachine();

            example.SubmitCommentCard(new CommentCard {
                IsComplaint = true
            });

            Assert.AreEqual(ExampleStateMachine.WaitingForManager, example.CurrentState);
        }
Ejemplo n.º 3
0
        public void Multiple_expressions_per_event_should_run_in_order()
        {
            ExampleStateMachine example = new ExampleStateMachine();

            example.SubmitCommentCard(new CommentCard {
                IsComplaint = true
            });

            Assert.AreEqual(ExampleStateMachine.WaitingForManager, example.CurrentState);

            example.BurnCommentCard();

            Assert.AreEqual(ExampleStateMachine.Completed, example.CurrentState);
        }