ResponseHandlerAnnotationHandler extends NoOpAnnotationHandler<ResponseHandler> { @Override public void handleInterfaceAnnotation(ResponseHandler annotation, InterfaceConfigBuilder builder)throws InvocationTargetException, NoSuchMethodException, IllegalAccessException, InstantiationException { builder.setMethodsResponseHandler(annotation.value()); }  @Override void handleInterfaceAnnotation(ResponseHandler annotation, InterfaceConfigBuilder builder); @Override void handleMethodAnnotation(ResponseHandler annotation, MethodConfigBuilder builder);  }
@Test public void handleInterfaceAnnotationShouldSetMethodsResponseHandler() throws Exception { when(mockAnnotation.value()).thenReturn((Class) DefaultResponseHandler.class); toTest.handleInterfaceAnnotation(mockAnnotation, mockInterfaceConfigBuilder); verify(mockAnnotation).value(); verify(mockInterfaceConfigBuilder).setMethodsResponseHandler(DefaultResponseHandler.class); }