use of org.testng.annotations.AfterClass in project OpenAM by OpenRock.
the class PrivilegeRestTest method cleanup.
@AfterClass
public void cleanup() throws Exception {
PrivilegeManager pm = PrivilegeManager.getInstance("/", adminSubject);
pm.remove(PRIVILEGE_NAME);
}
use of org.testng.annotations.AfterClass in project OpenAM by OpenRock.
the class MultipleResourceRestTest method cleanup.
@AfterClass
public void cleanup() throws Exception {
PrivilegeManager pm = PrivilegeManager.getInstance(REALM, adminSubject);
pm.remove(PRIVILEGE_NAME + "1");
pm.remove(PRIVILEGE_NAME + "2");
IdRepoUtils.deleteIdentity(REALM, user);
}
use of org.testng.annotations.AfterClass in project OpenAM by OpenRock.
the class PrivilegeManagerTest method cleanup.
@AfterClass
public void cleanup() throws Exception {
if (!migrated) {
return;
}
//Sub Realm
PrivilegeManager prmSubReam = PrivilegeManager.getInstance(SUB_REALM, SubjectUtils.createSubject(adminToken));
prmSubReam.remove(PRIVILEGE_NAME);
PrivilegeManager prm = PrivilegeManager.getInstance("/", SubjectUtils.createSubject(adminToken));
prm.remove(PRIVILEGE_NAME);
ApplicationManager.deleteApplication(adminSubject, "/", APPL_NAME);
ApplicationManager.deleteApplication(adminSubject, SUB_REALM, APPL_NAME);
OrganizationConfigManager orgMgr = new OrganizationConfigManager(adminToken, "/");
orgMgr.deleteSubOrganization(SUB_REALM, true);
}
use of org.testng.annotations.AfterClass in project OpenAM by OpenRock.
the class OrgAliasReferralTest method cleanup.
@AfterClass
public void cleanup() throws Exception {
if (orgAliasEnabled) {
OrganizationConfigManager ocm = new OrganizationConfigManager(adminToken, "/");
ocm.deleteSubOrganization(SUB_REALM1.substring(1), true);
}
}
use of org.testng.annotations.AfterClass in project OpenAM by OpenRock.
the class ReferredResourcesTest method cleanup.
@AfterClass
public void cleanup() throws Exception {
if (!migrated) {
return;
}
ApplicationManager.deleteApplication(adminSubject, "/", APPL_NAME);
OrganizationConfigManager ocm = new OrganizationConfigManager(adminToken, "/");
String subRealm = SUB_REALM1.substring(1);
ocm.deleteSubOrganization(subRealm, true);
subRealm = SUB_REALM2.substring(1);
ocm.deleteSubOrganization(subRealm, true);
subRealm = SUB_REALM3.substring(1);
ocm.deleteSubOrganization(subRealm, true);
}
Aggregations