### Question:
AuditAuthenticator implements IAuthenticator { @Override public boolean requireAuthentication() { return wrappedAuthenticator.requireAuthentication(); } AuditAuthenticator();   AuditAuthenticator(IDecoratedAuthenticator wrappedAuthenticator, AuditAdapter auditAdapter); @Override boolean requireAuthentication(); @Override Set<? extends IResource> protectedResources(); @Override void validateConfiguration(); @Override void setup(); @Override SaslNegotiator newSaslNegotiator(); @Override AuthenticatedUser legacyAuthenticate(Map<String, String> credentials);  }### Answer:
@Test public void testRequireAuthenticationIsDelegated() { when(mockAuthenticator.requireAuthentication()).thenReturn(true); assertThat(auditAuthenticator.requireAuthentication()).isTrue(); verify(mockAuthenticator, times(1)).requireAuthentication(); }