ConnectionTimeoutAnnotationHandler extends NoOpAnnotationHandler<ConnectionTimeout> { @Override public void handleInterfaceAnnotation(ConnectionTimeout annotation, InterfaceConfigBuilder builder) { builder.setMethodsConnectionTimeout(annotation.value()); }  @Override void handleInterfaceAnnotation(ConnectionTimeout annotation, InterfaceConfigBuilder builder); @Override void handleMethodAnnotation(ConnectionTimeout annotation, MethodConfigBuilder builder);  }
@Test public void handleInterfaceAnnotationShouldSetMethodsConnectionTimeout() throws Exception { when(mockAnnotation.value()).thenReturn(12); toTest.handleInterfaceAnnotation(mockAnnotation, mockInterfaceConfigBuilder); verify(mockAnnotation).value(); verify(mockInterfaceConfigBuilder).setMethodsConnectionTimeout(12); }