### Question:
AuditAuthenticator implements IAuthenticator { @VisibleForTesting static IDecoratedAuthenticator newWrappedAuthenticator(AuditConfig auditConfig) { String className = auditConfig.getWrappedAuthenticator(); return FBUtilities.construct(className, "authenticator"); } 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 testConstructFromAuditConfigWorksAsExpected() { String wrappedAuthenticatorName = DecoratedPasswordAuthenticator.class.getName(); when(mockConfig.getWrappedAuthenticator()).thenReturn(wrappedAuthenticatorName); IDecoratedAuthenticator wrappedAuthenticator = AuditAuthenticator.newWrappedAuthenticator(mockConfig); assertThat(wrappedAuthenticator).isInstanceOf(DecoratedPasswordAuthenticator.class); }