@Test public void exceptionWrapping() throws NoSuchMethodException {
    Method method = getExceptionThrowingMethod();
    EventHandler handler = new EventHandler(this, method);

    try {
      handler.handleEvent(new Object());
      fail("Handlers whose methods throw must throw InvocationTargetException");
    } catch (InvocationTargetException e) {
      assertTrue("Expected exception must be wrapped.",
          e.getCause() instanceof IntentionalException);
    }
  }
Checks that EventHandler's constructor disallows null targets.
otto/src/test/java/com/squareup/otto/EventHandlerTest.java