use of com.emc.storageos.svcs.errorhandling.resources.ForbiddenException in project coprhd-controller by CoprHD.
the class ServiceCodeExceptionTest method invalidContext.
@Test
public void invalidContext() {
final ForbiddenException exception = APIException.forbidden.invalidSecurityContext();
assertApiInsufficientPermissions("Invalid security context", exception);
}
use of com.emc.storageos.svcs.errorhandling.resources.ForbiddenException in project coprhd-controller by CoprHD.
the class ServiceCodeExceptionTest method insufficientPermissions.
@Test
public void insufficientPermissions() {
final String user = "user";
final ForbiddenException exception = APIException.forbidden.insufficientPermissionsForUser(user);
assertApiInsufficientPermissions("Insufficient permissions for user " + user + ".", exception);
}
use of com.emc.storageos.svcs.errorhandling.resources.ForbiddenException in project coprhd-controller by CoprHD.
the class ServiceCodeExceptionTest method internalAPI.
@Test
public void internalAPI() {
final ForbiddenException exception = APIException.forbidden.internalAPICannotBeUsed();
assertApiInsufficientPermissions("Internal api can not be used with public resources", exception);
}
Aggregations