Search in sources :

Example 36 with SecurityTeam

use of cz.metacentrum.perun.core.api.SecurityTeam in project perun by CESNET.

the class FacilitiesManagerEntryIntegrationTest method setUpSecurityTeam2.

private SecurityTeam setUpSecurityTeam2() throws Exception {
    SecurityTeam st = new SecurityTeam("Security2", "Description test 2");
    perun.getSecurityTeamsManagerBl().createSecurityTeam(sess, st);
    return st;
}
Also used : SecurityTeam(cz.metacentrum.perun.core.api.SecurityTeam)

Example 37 with SecurityTeam

use of cz.metacentrum.perun.core.api.SecurityTeam in project perun by CESNET.

the class FacilitiesManagerEntryIntegrationTest method assignSecurityTeamFacilityNotExists.

@Test(expected = FacilityNotExistsException.class)
public void assignSecurityTeamFacilityNotExists() throws Exception {
    System.out.println(CLASS_NAME + "assignSecurityTeamFacilityNotExists");
    SecurityTeam st0 = setUpSecurityTeam0();
    setUpSecurityTeam1();
    // should throw an exception
    facilitiesManagerEntry.assignSecurityTeam(sess, new Facility(0, "Name"), st0);
}
Also used : SecurityTeam(cz.metacentrum.perun.core.api.SecurityTeam) BanOnFacility(cz.metacentrum.perun.core.api.BanOnFacility) Facility(cz.metacentrum.perun.core.api.Facility) AbstractPerunIntegrationTest(cz.metacentrum.perun.core.AbstractPerunIntegrationTest) Test(org.junit.Test)

Aggregations

SecurityTeam (cz.metacentrum.perun.core.api.SecurityTeam)37 AbstractPerunIntegrationTest (cz.metacentrum.perun.core.AbstractPerunIntegrationTest)30 Test (org.junit.Test)30 ArrayList (java.util.ArrayList)4 BanOnFacility (cz.metacentrum.perun.core.api.BanOnFacility)3 InternalErrorException (cz.metacentrum.perun.core.api.exceptions.InternalErrorException)3 AuthzRoles (cz.metacentrum.perun.core.impl.AuthzRoles)3 Facility (cz.metacentrum.perun.core.api.Facility)2 Group (cz.metacentrum.perun.core.api.Group)2 ContactGroup (cz.metacentrum.perun.core.api.ContactGroup)1 Host (cz.metacentrum.perun.core.api.Host)1 User (cz.metacentrum.perun.core.api.User)1 BanNotExistsException (cz.metacentrum.perun.core.api.exceptions.BanNotExistsException)1 PrivilegeException (cz.metacentrum.perun.core.api.exceptions.PrivilegeException)1 RelationExistsException (cz.metacentrum.perun.core.api.exceptions.RelationExistsException)1 SecurityTeamExistsException (cz.metacentrum.perun.core.api.exceptions.SecurityTeamExistsException)1 SecurityTeamNotExistsException (cz.metacentrum.perun.core.api.exceptions.SecurityTeamNotExistsException)1 WrongAttributeValueException (cz.metacentrum.perun.core.api.exceptions.WrongAttributeValueException)1 WrongReferenceAttributeValueException (cz.metacentrum.perun.core.api.exceptions.WrongReferenceAttributeValueException)1 HashSet (java.util.HashSet)1