use of edu.uiuc.ncsa.myproxy.oa4mp.oauth2.cm.ldap.LDAPEntry in project OA4MP by ncsa.
the class ClientManagerTest method testLDAPStore2.
/**
* Retrieve a configuration by its client id.
*
* @param ldapStore
* @param clientStore
* @throws Exception
*/
public void testLDAPStore2(LDAPStore<LDAPEntry> ldapStore, ClientStore clientStore) throws Exception {
OA2Client oa2Client = (OA2Client) clientStore.create();
LDAPConfiguration ldap = createLDAP();
LDAPEntry ldapEntry = ldapStore.create();
ldapEntry.setClientID(oa2Client.getIdentifier());
ldapEntry.setConfiguration(ldap);
ldapStore.save(ldapEntry);
LDAPEntry ldapEntry1 = ldapStore.getByClientID(ldapEntry.getClientID());
assert ldapEntry.equals(ldapEntry1);
}
use of edu.uiuc.ncsa.myproxy.oa4mp.oauth2.cm.ldap.LDAPEntry in project OA4MP by ncsa.
the class ClientManagerTest method testLDAPStore.
public void testLDAPStore(LDAPStore<LDAPEntry> ldapStore, ClientStore clientStore) throws Exception {
OA2Client oa2Client = (OA2Client) clientStore.create();
LDAPConfiguration ldap = createLDAP();
LDAPEntry ldapEntry = ldapStore.create();
ldapEntry.setClientID(oa2Client.getIdentifier());
ldapEntry.setConfiguration(ldap);
ldapStore.save(ldapEntry);
LDAPEntry ldapEntry1 = ldapStore.get(ldapEntry.getIdentifier());
assert ldapEntry.equals(ldapEntry1);
}
Aggregations