#22461 #1

Merged
fabio.sinibaldi merged 27 commits from #22461 into master 2022-01-14 12:43:19 +01:00
1 changed files with 4 additions and 2 deletions
Showing only changes of commit ce867018a7 - Show all commits

View File

@ -10,11 +10,13 @@ import org.gcube.application.geoportal.common.model.legacy.Concessione;
import org.gcube.application.geoportal.common.model.legacy.Concessione.Paths;
import org.gcube.application.geoportal.common.model.legacy.LayerConcessione;
import org.gcube.application.geoportal.common.model.legacy.report.ValidationReport.ValidationStatus;
import org.gcube.application.geoportal.common.model.rest.QueryRequest;
import org.gcube.application.geoportal.common.rest.InterfaceConstants;
import org.gcube.application.geoportal.common.utils.FileSets;
import org.gcube.application.geoportal.common.utils.Files;
import org.gcube.application.geoportal.common.utils.StorageUtils;
import org.gcube.application.geoportal.service.utils.Serialization;
import org.gcube.common.storagehub.model.query.Queries;
import org.json.JSONObject;
import org.junit.Assert;
import org.junit.Before;
@ -113,10 +115,10 @@ public class ConcessioniOverMongoTest extends BasicServiceTestUnit{
private static <T> Iterator<T> queryFile(String filename, WebTarget target, Class<T> clazz) throws Exception {
String queryString=TestConcessioniQueries.queries.get(filename);
QueryRequest req= Serialization.parseQuery(TestConcessioniQueries.queries.get(filename));
String result = check(target.path(InterfaceConstants.Methods.QUERY_PATH).request(MediaType.APPLICATION_JSON_TYPE).post(
Entity.entity(queryString,MediaType.APPLICATION_JSON)),String.class);
Entity.entity(Serialization.write(req),MediaType.APPLICATION_JSON)),String.class);
return Serialization.readCollection(result,clazz);
}