Added test

This commit is contained in:
Luca Frosini 2019-10-01 17:59:20 +02:00
parent c3efcb43fd
commit d17c843cf0
1 changed files with 14 additions and 1 deletions

View File

@ -7,6 +7,7 @@ import java.util.List;
import java.util.Map;
import java.util.concurrent.TimeUnit;
import org.gcube.gcat.api.GCatConstants;
import org.junit.Assert;
import org.junit.Test;
import org.slf4j.Logger;
@ -155,7 +156,19 @@ public class ItemTest extends ContextTest {
ContextTest.setContextByName("/gcube/devNext");
Item item = new Item();
String itemsString = item.list(10, 0, "bionym");
String itemsString = item.list(10, 0, "dorne");
logger.debug("Got list {}", itemsString);
Map<String, String> queryParams = new HashMap<>();
queryParams.put(GCatConstants.Q_KEY, "organization:dorne OR organization:ckand4scienceharvest");
itemsString = item.list(queryParams);
logger.debug("Got list {}", itemsString);
queryParams = new HashMap<>();
queryParams.put(GCatConstants.Q_KEY, "organization:ckand4scienceharvest");
queryParams.put("rows", "4");
queryParams.put("start", "4");
itemsString = item.list(queryParams);
logger.debug("Got list {}", itemsString);
/*