예제 #1
0
        public void Validate_WhenCommandDefined_CallsExpectedValidator()
        {
            // Arrange
            var command = new FakeCommand1();

            // Act
            this.processor.Validate(command);
            // Assert
            this.validatorOfCommand1.Received(1).Validate(command);
        }
예제 #2
0
        public void Process_WhenCommandDefined_CallsExpectedHandler()
        {
            // Arrange
            var command = new FakeCommand1();

            // Act
            this.processor.Process(command);
            // Assert
            this.handlerOfCommand1.Received(1).Handle(command);
        }