@Test
public void runnableException() throws InterruptedException {

  doThrow(RuntimeException.class).when(runnable).run();
  underTest = new BlockingExecutor(delegate, semaphore);
  underTest.execute(runnable);
  InOrder inOrder = inOrder(delegate, semaphore);
  inOrder.verify(semaphore).acquire();
  inOrder.verify(delegate).execute(captor.capture());
  inOrder.verify(semaphore, never()).release();
  try {
    captor.getValue().run();
    fail();
  } catch (RuntimeException e) {
    InOrder inOrder2 = inOrder(runnable, semaphore);
    inOrder2.verify(runnable).run();
    inOrder2.verify(semaphore).release();
  }
}