Package net.shibboleth.idp.authn.config
Class LDAPAuthenticationFactoryBeanTest
- java.lang.Object
-
- net.shibboleth.idp.authn.config.LDAPAuthenticationFactoryBeanTest
-
public class LDAPAuthenticationFactoryBeanTest extends Object
Unit test for LDAP authentication factory bean.
-
-
Field Summary
Fields Modifier and Type Field Description private Authenticatorauthenticatorprivate static StringDATA_PATHprivate com.unboundid.ldap.listener.InMemoryDirectoryServerdirectoryServerprivate net.shibboleth.idp.authn.config.LDAPAuthenticationFactoryBeanfactoryBean
-
Constructor Summary
Constructors Constructor Description LDAPAuthenticationFactoryBeanTest()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private AuthenticationRequestcreateAuthenticationRequest(String username, String password)voidsetupAuthenticator()voidsetupDirectoryServer()Creates an UnboundID in-memory directory server.voidteardownDirectoryServer()Shutdown the in-memory directory server.voidtestAuthnFailure()voidtestAuthnSuccess()
-
-
-
Field Detail
-
DATA_PATH
private static final String DATA_PATH
- See Also:
- Constant Field Values
-
directoryServer
private com.unboundid.ldap.listener.InMemoryDirectoryServer directoryServer
-
factoryBean
private net.shibboleth.idp.authn.config.LDAPAuthenticationFactoryBean factoryBean
-
authenticator
private Authenticator authenticator
-
-
Method Detail
-
setupDirectoryServer
@BeforeClass public void setupDirectoryServer() throws com.unboundid.ldap.sdk.LDAPExceptionCreates an UnboundID in-memory directory server. Leverages LDIF found in test resources.- Throws:
com.unboundid.ldap.sdk.LDAPException- if the in-memory directory server cannot be created
-
teardownDirectoryServer
@AfterClass public void teardownDirectoryServer()
Shutdown the in-memory directory server.
-
setupAuthenticator
@BeforeMethod public void setupAuthenticator() throws Exception- Throws:
Exception
-
createAuthenticationRequest
private AuthenticationRequest createAuthenticationRequest(String username, String password)
-
-