Esempio n. 1
0
        public async Task OnErrorShouldInvokeProcessIfCanHandleReturnsTrue()
        {
            Exception           exception = new DivideByZeroException();
            IErrorHandlerPlugin plugin    = CreateErrorHandlerPlugin(1);

            plugin.CanHandle(exception).Returns(true);
            this.bootstrapper.GetErrorHandlers().Returns(new[] { plugin });

            await this.processor.OnError(this.request, exception);

            await plugin.Received().Process(this.request, exception);
        }