use of org.testng.annotations.AfterClass in project OpenAM by OpenRock.
the class PolicyWildcardTest method cleanup.
@AfterClass
public void cleanup() throws PolicyException, SSOException, IdRepoException {
SSOTokenManager.getInstance().destroyToken(userSSOToken);
SSOTokenManager.getInstance().destroyToken(adminUserSSOToken);
PolicyManager pm = new PolicyManager(adminToken, REALM);
pm.removePolicy(POLICY_NAME_USER);
pm.removePolicy(POLICY_NAME_ADMIN);
AMIdentityRepository amir = new AMIdentityRepository(adminToken, REALM);
Set<AMIdentity> identities = new HashSet<AMIdentity>();
identities.add(testAdminGroup);
identities.add(testAdminUser);
identities.add(testUser);
amir.deleteIdentities(identities);
}
use of org.testng.annotations.AfterClass in project midpoint by Evolveum.
the class AbstractModelIntegrationTest method cleanUpSecurity.
@AfterClass
protected void cleanUpSecurity() {
SecurityContext securityContext = SecurityContextHolder.getContext();
securityContext.setAuthentication(null);
}
Aggregations