Exemplo n.º 1
0
        public void ExecutionResult_Should_Contain_Errors_When_ServiceException_Is_Caught()
        {
            var command = new MockCommandThrowsErrorsOnExecute();
            var result  = command.Execute();

            result.Errors.Count().ShouldBe(1);
        }
Exemplo n.º 2
0
        public async Task ExecutionResult_Should_Contain_Errors_When_ServiceException_Is_Caught_Async()
        {
            var command = new MockCommandThrowsErrorsOnExecute();
            var result  = await command.ExecuteAsync();

            result.Errors.Count().ShouldBe(1);
        }