Merged 5.2.N (5.2.1) to HEAD (5.2)

130179 gjames: Merged searchapi (5.2.1) to 5.2.N (5.2.1)
      129819 gjames: SEARCH-113: The Json representation is immutable.


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@130330 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Alan Davis
2016-09-06 22:04:33 +00:00
parent a0a62612f4
commit e9783d8e04
4 changed files with 36 additions and 47 deletions

View File

@@ -111,7 +111,7 @@ public class ResultMapperTests
@Test
public void testNoResults() throws Exception
{
CollectionWithPagingInfo<Node> collection = mapper.toCollectionWithPagingInfo(mockParams(new SearchQuery()),new EmptyResultSet());
CollectionWithPagingInfo<Node> collection = mapper.toCollectionWithPagingInfo(mockParams(SearchQuery.EMPTY),new EmptyResultSet());
assertNotNull(collection);
assertFalse(collection.hasMoreItems());
assertTrue(collection.getTotalItems() < 1);
@@ -121,7 +121,7 @@ public class ResultMapperTests
public void testToCollectionWithPagingInfo() throws Exception
{
ResultSet results = mockResultset();
CollectionWithPagingInfo<Node> collectionWithPage = mapper.toCollectionWithPagingInfo(mockParams(new SearchQuery()),results);
CollectionWithPagingInfo<Node> collectionWithPage = mapper.toCollectionWithPagingInfo(mockParams(SearchQuery.EMPTY),results);
assertNotNull(collectionWithPage);
Long found = results.getNumberFound();
assertEquals(found.intValue(), collectionWithPage.getTotalItems().intValue());