public void ShouldHandleFatalException() { var causeException = new Exception(); var evt = new StubEvent(0); var exceptionHandler = new FatalExceptionHandler <StubEvent>(); var exception = Assert.Throws <ApplicationException>(() => exceptionHandler.HandleEventException(causeException, 0L, evt)); Assert.IsNotNull(exception); Assert.AreEqual(causeException, exception !.InnerException); }
public void ShouldHandleFatalException() { var causeException = new Exception(); var evt = new StubEvent(0); var exceptionHandler = new FatalExceptionHandler(); try { exceptionHandler.HandleEventException(causeException, 0L, evt); } catch (Exception ex) { Assert.AreEqual(causeException, ex.InnerException); } }
public void ShouldHandleFatalException() { var causeException = new Exception(); var evt = new StubEvent(0); var exceptionHandler = new FatalExceptionHandler(); try { exceptionHandler.HandleEventException(causeException, 0L, evt); } catch (Exception ex) { Assert.AreEqual(causeException, ex.InnerException); } }