@Test public void reports_internal_errors() { failureHandler.uncaughtException("the-actor", "the-message", new Throwable("the-exception-message")); String expected = String.format("Uncaught exception in thread %s from the-actor when processing the-message", Thread.currentThread().getName()); verify(suiteListener).onInternalError(eq(expected), notNull(StackTrace.class)); }
@Override public void uncaughtException(Object actor, Object message, Throwable exception) { reportInternalError("Uncaught exception in thread " + Thread.currentThread().getName() + " from " + actor + " when processing " + message, exception); }
InternalErrorReportingFailureHandler extends InternalErrorReporter implements FailureHandler { @Override public void uncaughtException(Object actor, Object message, Throwable exception) { reportInternalError("Uncaught exception in thread " + Thread.currentThread().getName() + " from " + actor + " when processing " + message, exception); } }
InternalErrorReportingFailureHandler extends InternalErrorReporter implements FailureHandler { @Override public void uncaughtException(Object actor, Object message, Throwable exception) { reportInternalError("Uncaught exception in thread " + Thread.currentThread().getName() + " from " + actor + " when processing " + message, exception); } InternalErrorReportingFailureHandler(SuiteListener listener, PrintStream out); }
InternalErrorReportingFailureHandler extends InternalErrorReporter implements FailureHandler { @Override public void uncaughtException(Object actor, Object message, Throwable exception) { reportInternalError("Uncaught exception in thread " + Thread.currentThread().getName() + " from " + actor + " when processing " + message, exception); } InternalErrorReportingFailureHandler(SuiteListener listener, PrintStream out); @Override void uncaughtException(Object actor, Object message, Throwable exception); }
InternalErrorReportingFailureHandler extends InternalErrorReporter implements FailureHandler { @Override public void uncaughtException(Object actor, Object message, Throwable exception) { reportInternalError("Uncaught exception in thread " + Thread.currentThread().getName() + " from " + actor + " when processing " + message, exception); } InternalErrorReportingFailureHandler(SuiteListener listener, PrintStream out); @Override void uncaughtException(Object actor, Object message, Throwable exception);  }