void (SuspendContextImpl suspendContext) { try { if (myScriptRunnables.isEmpty() && myRepeatingRunnables.isEmpty()) { print("resuming ", ProcessOutputTypes.SYSTEM); printContext(suspendContext); resume(suspendContext); return; } SuspendContextRunnable suspendContextRunnable = myScriptRunnables.poll(); if (suspendContextRunnable != null) { suspendContextRunnable.run(suspendContext); } for (SuspendContextRunnable it : myRepeatingRunnables) { it.run(suspendContext); } } catch (Exception e) { addException(e); error(e); } catch (AssertionError e) { addException(e); resume(suspendContext); } }