### Question:
MethodExceptionTypeMatcher extends ElementMatcher.Junction.AbstractBase<T> { public boolean matches(T target) { return matcher.matches(target.getExceptionTypes()); } MethodExceptionTypeMatcher(ElementMatcher<? super TypeList.Generic> matcher); boolean matches(T target); @Override String toString();  }### Answer:
@Test public void testMatch() throws Exception { when(exceptionMatcher.matches(typeList)).thenReturn(true); assertThat(new MethodExceptionTypeMatcher<MethodDescription>(exceptionMatcher).matches(methodDescription), is(true)); verify(exceptionMatcher).matches(typeList); verifyNoMoreInteractions(exceptionMatcher); }
@Test public void testNoMatch() throws Exception { when(exceptionMatcher.matches(typeList)).thenReturn(false); assertThat(new MethodExceptionTypeMatcher<MethodDescription>(exceptionMatcher).matches(methodDescription), is(false)); verify(exceptionMatcher).matches(typeList); verifyNoMoreInteractions(exceptionMatcher); }