use of com.emc.storageos.svcs.errorhandling.resources.ForbiddenException in project coprhd-controller by CoprHD.
the class ServiceCodeExceptionTest method noTenant.
@Test
public void noTenant() {
final String userName = "userName";
final ForbiddenException exception = APIException.forbidden.userDoesNotMapToAnyTenancy(userName);
assertApiInsufficientPermissions("User " + userName + " does not map to any tenancy", exception);
}
use of com.emc.storageos.svcs.errorhandling.resources.ForbiddenException in project coprhd-controller by CoprHD.
the class ServiceCodeExceptionTest method readingRoles.
@Test
public void readingRoles() {
final ForbiddenException exception = APIException.forbidden.failedReadingTenantRoles(null);
assertApiInsufficientPermissions("Failed reading tenant roles", exception);
}
use of com.emc.storageos.svcs.errorhandling.resources.ForbiddenException in project coprhd-controller by CoprHD.
the class ServiceCodeExceptionTest method onlyAdmin.
@Test
public void onlyAdmin() {
final ForbiddenException exception = APIException.forbidden.onlyAdminsCanProvisionFileSystems("system_admin", "tenant_admin");
assertApiInsufficientPermissions("Only [system_admin, tenant_admin] can provision file systems for object", exception);
}
use of com.emc.storageos.svcs.errorhandling.resources.ForbiddenException in project coprhd-controller by CoprHD.
the class ServiceCodeExceptionTest method notLogout.
@Test
public void notLogout() {
final String userName = "userName";
final ForbiddenException exception = APIException.forbidden.userNotPermittedToLogoutAnotherUser(userName);
assertApiInsufficientPermissions("User " + userName + " not permitted to logout another user", exception);
}
use of com.emc.storageos.svcs.errorhandling.resources.ForbiddenException in project coprhd-controller by CoprHD.
the class ServiceCodeExceptionTest method readingACLs.
@Test
public void readingACLs() {
final ForbiddenException exception = APIException.forbidden.failedReadingProjectACLs(null);
assertApiInsufficientPermissions("Failed reading project ACLs", exception);
}
Aggregations