mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-14 17:58:59 +00:00
ACE-5463: 500 error: GET /nodes/{nodeId}/comments?skipCount=XXX
-implemented fix and added new unit test git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/DEV/5.2.N/root@131470 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -777,6 +777,9 @@ public class TestNodeComments extends EnterpriseTestApi
|
|||||||
{
|
{
|
||||||
assertEquals(HttpStatus.SC_BAD_REQUEST, e.getHttpResponse().getStatusCode());
|
assertEquals(HttpStatus.SC_BAD_REQUEST, e.getHttpResponse().getStatusCode());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// ACE-5463
|
||||||
|
testSkipCountHighValue(expectedComments, commentsProxy);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@@ -941,4 +944,21 @@ public class TestNodeComments extends EnterpriseTestApi
|
|||||||
|
|
||||||
commentsProxy.removeNodeComment(nodeRef1.getId(), commentId);
|
commentsProxy.removeNodeComment(nodeRef1.getId(), commentId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// test for retrieving the list of comments with high value of skipCount(e.g. 10)
|
||||||
|
public void testSkipCountHighValue(List<Comment> expectedComments, Comments commentsProxy) throws PublicApiException
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
int skipCount = 10;
|
||||||
|
int maxItems = 2;
|
||||||
|
Paging paging = getPaging(skipCount, maxItems, expectedComments.size(), expectedComments.size());
|
||||||
|
commentsProxy.getNodeComments(nodeRef1.getId(), createParams(paging, null));
|
||||||
|
|
||||||
|
}
|
||||||
|
catch (IllegalStateException e)
|
||||||
|
{
|
||||||
|
fail();
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user