mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-14 17:58:59 +00:00
Merged HEAD (5.2) to 5.2.N (5.2.1)
126513 jkaabimofrad: Merged FILE-FOLDER-API (5.2.0) to HEAD (5.2) 122834 jkaabimofrad: RA-678: Modified the response, to return 409 rather than 400 when the rendition requested already exists. git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/DEV/5.2.N/root@126857 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -362,14 +362,14 @@ public class RenditionsTest extends AbstractBaseApiTest
|
||||
|
||||
// -ve Tests
|
||||
// The rendition requested already exists
|
||||
response = post(getRenditionsUrl(contentNodeId), userOneN1.getId(), toJsonAsString(new Rendition().setId("imgpreview")), 400);
|
||||
response = post(getRenditionsUrl(contentNodeId), userOneN1.getId(), toJsonAsString(new Rendition().setId("imgpreview")), 409);
|
||||
ExpectedErrorResponse errorResponse = RestApiUtil.parseErrorResponse(response.getJsonResponse());
|
||||
assertNotNull(errorResponse);
|
||||
assertNotNull(errorResponse.getErrorKey());
|
||||
assertNotNull(errorResponse.getBriefSummary());
|
||||
assertNotNull(errorResponse.getStackTrace());
|
||||
assertNotNull(errorResponse.getDescriptionURL());
|
||||
assertEquals(400, errorResponse.getStatusCode());
|
||||
assertEquals(409, errorResponse.getStatusCode());
|
||||
|
||||
// Create 'doclib' rendition request
|
||||
Rendition renditionRequest = new Rendition().setId("doclib");
|
||||
|
Reference in New Issue
Block a user