public void ThreadHelperRunnableNoExceptionHandler()
        {
            IRunnable runner = ThreadExceptionHandlerHelpers.AssignExceptionHandler(new NullRunnable(), new UncaughtExceptionHandlerDelegate(MyExceptionHandler));

            runner.Run();
            Assert.IsFalse(_handlerExecuted);
        }
        public void ThreadHelperRunnableRunsExceptionHandler()
        {
            IRunnable runner = ThreadExceptionHandlerHelpers.AssignExceptionHandler(new FailingRunnable(), new UncaughtExceptionHandlerDelegate(MyExceptionHandler));

            runner.Run();
            Assert.IsTrue(_handlerExecuted);
        }
 public void NullDelegateException()
 {
     ThreadExceptionHandlerHelpers.AssignExceptionHandler(new FailingRunnable(), null);
 }
 public void NullRunnableException()
 {
     ThreadExceptionHandlerHelpers.AssignExceptionHandler(null, new UncaughtExceptionHandlerDelegate(MyExceptionHandler));
 }