blob: 78739c7ba96c85c4e916eaaa3151e28568c37dab [file] [log] [blame]
Michael Hanlfb839b92015-09-19 21:32:34 +02001import com.fasterxml.jackson.databind.JsonNode;
Michael Hanl19390652016-01-16 11:01:24 +01002import de.ids_mannheim.korap.query.serialize.QuerySerializer;
Michael Hanlcb2d3f92016-06-02 17:34:06 +02003import de.ids_mannheim.korap.resources.KustvaktResource;
4import de.ids_mannheim.korap.resources.VirtualCollection;
Michael Hanl00b64e02016-05-24 20:24:27 +02005import de.ids_mannheim.korap.utils.KoralCollectionQueryBuilder;
Michael Hanlfb839b92015-09-19 21:32:34 +02006import de.ids_mannheim.korap.utils.JsonUtils;
Michael Hanlcedf7212016-05-28 10:43:09 +02007import org.junit.Ignore;
Michael Hanlfb839b92015-09-19 21:32:34 +02008import org.junit.Test;
9
Michael Hanldaf86602016-05-12 14:31:52 +020010import static org.junit.Assert.assertEquals;
Michael Hanl00b64e02016-05-24 20:24:27 +020011import static org.junit.Assert.assertNotEquals;
Michael Hanldaf86602016-05-12 14:31:52 +020012import static org.junit.Assert.assertNotNull;
13
Michael Hanlfb839b92015-09-19 21:32:34 +020014/**
15 * @author hanl
16 * @date 12/08/2015
17 */
18public class CollectionQueryBuilderTest {
19
20 @Test
Michael Hanl8abaf9e2016-05-23 16:46:35 +020021 public void testsimpleAdd () {
Michael Hanl00b64e02016-05-24 20:24:27 +020022 KoralCollectionQueryBuilder b = new KoralCollectionQueryBuilder();
23 b.with("corpusSigle=WPD");
Michael Hanl482f30d2015-09-25 12:39:46 +020024
25 JsonNode node = JsonUtils.readTree(b.toJSON());
26
Michael Hanldaf86602016-05-12 14:31:52 +020027 assertNotNull(node);
Michael Hanl8abaf9e2016-05-23 16:46:35 +020028 assertEquals("koral:doc", node.at("/collection/@type").asText());
Michael Hanl00b64e02016-05-24 20:24:27 +020029 assertEquals("corpusSigle", node.at("/collection/key").asText());
Michael Hanlfb839b92015-09-19 21:32:34 +020030 }
31
Michael Hanl8abaf9e2016-05-23 16:46:35 +020032
Michael Hanlfb839b92015-09-19 21:32:34 +020033 @Test
Michael Hanl8abaf9e2016-05-23 16:46:35 +020034 public void testSimpleConjunction () {
Michael Hanl00b64e02016-05-24 20:24:27 +020035 KoralCollectionQueryBuilder b = new KoralCollectionQueryBuilder();
36 b.with("corpusSigle=WPD & textClass=freizeit");
Michael Hanl482f30d2015-09-25 12:39:46 +020037 JsonNode node = JsonUtils.readTree(b.toJSON());
38
Michael Hanldaf86602016-05-12 14:31:52 +020039 assertNotNull(node);
Michael Hanl8abaf9e2016-05-23 16:46:35 +020040 assertEquals("koral:docGroup", node.at("/collection/@type").asText());
41 assertEquals("operation:and", node.at("/collection/operation").asText());
Michael Hanldaf86602016-05-12 14:31:52 +020042
Michael Hanl33829ec2016-05-28 17:03:38 +020043 assertEquals("corpusSigle", node.at("/collection/operands/0/key")
44 .asText());
Michael Hanl8abaf9e2016-05-23 16:46:35 +020045 assertEquals("textClass", node.at("/collection/operands/1/key")
46 .asText());
Michael Hanlfb839b92015-09-19 21:32:34 +020047 }
48
Michael Hanl8abaf9e2016-05-23 16:46:35 +020049
Michael Hanlfb839b92015-09-19 21:32:34 +020050 @Test
Michael Hanl8abaf9e2016-05-23 16:46:35 +020051 public void testSimpleDisjunction () {
Michael Hanl00b64e02016-05-24 20:24:27 +020052 KoralCollectionQueryBuilder b = new KoralCollectionQueryBuilder();
53 b.with("corpusSigle=WPD | textClass=freizeit");
Michael Hanl482f30d2015-09-25 12:39:46 +020054 JsonNode node = JsonUtils.readTree(b.toJSON());
55
Michael Hanl00b64e02016-05-24 20:24:27 +020056 assertNotNull(node);
Michael Hanl482f30d2015-09-25 12:39:46 +020057 assert node.at("/collection/operation").asText().equals("operation:or");
58 assert node.at("/collection/operands/0/key").asText()
Michael Hanl00b64e02016-05-24 20:24:27 +020059 .equals("corpusSigle");
Michael Hanl482f30d2015-09-25 12:39:46 +020060 assert node.at("/collection/operands/1/key").asText()
61 .equals("textClass");
Michael Hanlfb839b92015-09-19 21:32:34 +020062 }
63
Michael Hanl8abaf9e2016-05-23 16:46:35 +020064
Michael Hanlfb839b92015-09-19 21:32:34 +020065 @Test
Michael Hanl8abaf9e2016-05-23 16:46:35 +020066 public void testComplexSubQuery () {
Michael Hanl00b64e02016-05-24 20:24:27 +020067 KoralCollectionQueryBuilder b = new KoralCollectionQueryBuilder();
68 b.with("(corpusSigle=WPD) | (textClass=freizeit & corpusSigle=BRZ13)");
Michael Hanl482f30d2015-09-25 12:39:46 +020069 JsonNode node = JsonUtils.readTree(b.toJSON());
Michael Hanlfb839b92015-09-19 21:32:34 +020070
Michael Hanl00b64e02016-05-24 20:24:27 +020071 assertNotNull(node);
Michael Hanl482f30d2015-09-25 12:39:46 +020072 assert node.at("/collection/operation").asText().equals("operation:or");
73 assert node.at("/collection/operands/0/key").asText()
Michael Hanl00b64e02016-05-24 20:24:27 +020074 .equals("corpusSigle");
Michael Hanl482f30d2015-09-25 12:39:46 +020075 assert node.at("/collection/operands/1/@type").asText()
76 .equals("koral:docGroup");
Michael Hanlfb839b92015-09-19 21:32:34 +020077
Michael Hanlfb839b92015-09-19 21:32:34 +020078 }
79
Michael Hanl8abaf9e2016-05-23 16:46:35 +020080
Michael Hanlfb839b92015-09-19 21:32:34 +020081 @Test
Michael Hanl8abaf9e2016-05-23 16:46:35 +020082 public void testAddResourceQueryAfter () {
Michael Hanl00b64e02016-05-24 20:24:27 +020083 KoralCollectionQueryBuilder b = new KoralCollectionQueryBuilder();
84 b.with("(textClass=politik & title=\"random title\") | textClass=wissenschaft");
Michael Hanlfb839b92015-09-19 21:32:34 +020085
Michael Hanl00b64e02016-05-24 20:24:27 +020086 KoralCollectionQueryBuilder c = new KoralCollectionQueryBuilder();
Michael Hanlfb839b92015-09-19 21:32:34 +020087 c.setBaseQuery(b.toJSON());
Michael Hanl00b64e02016-05-24 20:24:27 +020088 c.with("corpusSigle=WPD");
Michael Hanlfb839b92015-09-19 21:32:34 +020089
90 JsonNode node = JsonUtils.readTree(c.toJSON());
Michael Hanl00b64e02016-05-24 20:24:27 +020091 assertNotNull(node);
Michael Hanlcedf7212016-05-28 10:43:09 +020092 assertEquals("koral:doc", node.at("/collection/operands/1/@type")
Michael Hanl00b64e02016-05-24 20:24:27 +020093 .asText());
Michael Hanlcedf7212016-05-28 10:43:09 +020094 assertEquals("koral:docGroup", node.at("/collection/operands/0/@type")
95 .asText());
Michael Hanl00b64e02016-05-24 20:24:27 +020096 assertEquals(2, node.at("/collection/operands").size());
Michael Hanlcedf7212016-05-28 10:43:09 +020097 assertEquals(2, node.at("/collection/operands/0/operands").size());
Michael Hanl33829ec2016-05-28 17:03:38 +020098 assertEquals(2, node.at("/collection/operands/0/operands/0/operands")
99 .size());
Michael Hanlcedf7212016-05-28 10:43:09 +0200100
101 assertEquals("operation:and", node.at("/collection/operation").asText());
Michael Hanl33829ec2016-05-28 17:03:38 +0200102 assertEquals("operation:or", node
103 .at("/collection/operands/0/operation").asText());
104 assertEquals("operation:and",
105 node.at("/collection/operands/0/operands/0/operation").asText());
Michael Hanlcedf7212016-05-28 10:43:09 +0200106 assertEquals("WPD", node.at("/collection/operands/1/value").asText());
Michael Hanlfb839b92015-09-19 21:32:34 +0200107 }
108
Michael Hanl8abaf9e2016-05-23 16:46:35 +0200109
Michael Hanl482f30d2015-09-25 12:39:46 +0200110 @Test
Michael Hanl8abaf9e2016-05-23 16:46:35 +0200111 public void testAddComplexResourceQueryAfter () {
Michael Hanl00b64e02016-05-24 20:24:27 +0200112 KoralCollectionQueryBuilder b = new KoralCollectionQueryBuilder();
113 b.with("(title=\"random title\") | (textClass=wissenschaft)");
Michael Hanl482f30d2015-09-25 12:39:46 +0200114
Michael Hanl00b64e02016-05-24 20:24:27 +0200115 KoralCollectionQueryBuilder c = new KoralCollectionQueryBuilder();
Michael Hanl482f30d2015-09-25 12:39:46 +0200116 c.setBaseQuery(b.toJSON());
Michael Hanl00b64e02016-05-24 20:24:27 +0200117 c.with("(corpusSigle=BRZ13 | corpusSigle=AZPS)");
Michael Hanl482f30d2015-09-25 12:39:46 +0200118
119 JsonNode node = JsonUtils.readTree(c.toJSON());
Michael Hanl00b64e02016-05-24 20:24:27 +0200120 assertNotNull(node);
121 assertEquals("koral:docGroup", node.at("/collection/operands/0/@type")
122 .asText());
123 assertEquals("koral:docGroup", node.at("/collection/operands/1/@type")
124 .asText());
125 assertEquals("BRZ13", node
Michael Hanlcedf7212016-05-28 10:43:09 +0200126 .at("/collection/operands/1/operands/0/value").asText());
127 assertEquals("AZPS", node.at("/collection/operands/1/operands/1/value")
Michael Hanl00b64e02016-05-24 20:24:27 +0200128 .asText());
129 assertEquals("random title",
Michael Hanlcedf7212016-05-28 10:43:09 +0200130 node.at("/collection/operands/0/operands/0/value").asText());
Michael Hanl00b64e02016-05-24 20:24:27 +0200131 assertEquals("wissenschaft",
Michael Hanlcedf7212016-05-28 10:43:09 +0200132 node.at("/collection/operands/0/operands/1/value").asText());
Michael Hanl482f30d2015-09-25 12:39:46 +0200133 }
134
Michael Hanl8abaf9e2016-05-23 16:46:35 +0200135
Michael Hanl19390652016-01-16 11:01:24 +0100136 @Test
Michael Hanl00b64e02016-05-24 20:24:27 +0200137 public void testBuildQuery () {
138 String coll = "corpusSigle=WPD";
Michael Hanl19390652016-01-16 11:01:24 +0100139 String query = "[base=Haus]";
Michael Hanl00b64e02016-05-24 20:24:27 +0200140 QuerySerializer check = new QuerySerializer();
141 check.setQuery(query, "poliqarp");
142 check.setCollection(coll);
Michael Hanl19390652016-01-16 11:01:24 +0100143
Michael Hanl00b64e02016-05-24 20:24:27 +0200144 KoralCollectionQueryBuilder b = new KoralCollectionQueryBuilder();
145 b.setBaseQuery(check.toJSON());
146 b.with("textClass=freizeit");
147
Michael Hanlcb2d3f92016-06-02 17:34:06 +0200148 JsonNode res = (JsonNode) b.rebaseCollection(null);
Michael Hanl00b64e02016-05-24 20:24:27 +0200149 assertNotNull(res);
150 assertEquals("koral:docGroup", res.at("/collection/@type").asText());
151 assertEquals("operation:and", res.at("/collection/operation").asText());
152 assertEquals("koral:doc", res.at("/collection/operands/0/@type")
153 .asText());
Michael Hanlcedf7212016-05-28 10:43:09 +0200154 assertEquals("freizeit", res.at("/collection/operands/1/value")
Michael Hanl00b64e02016-05-24 20:24:27 +0200155 .asText());
Michael Hanlcedf7212016-05-28 10:43:09 +0200156 assertEquals("textClass", res.at("/collection/operands/1/key").asText());
Michael Hanl00b64e02016-05-24 20:24:27 +0200157
158 assertEquals("koral:doc", res.at("/collection/operands/1/@type")
159 .asText());
Michael Hanlcedf7212016-05-28 10:43:09 +0200160 assertEquals("WPD", res.at("/collection/operands/0/value").asText());
Michael Hanl33829ec2016-05-28 17:03:38 +0200161 assertEquals("corpusSigle", res.at("/collection/operands/0/key")
162 .asText());
Michael Hanl00b64e02016-05-24 20:24:27 +0200163
164 // check also that query is still there
165 assertEquals("koral:token", res.at("/query/@type").asText());
166 assertEquals("koral:term", res.at("/query/wrap/@type").asText());
167 assertEquals("Haus", res.at("/query/wrap/key").asText());
168 assertEquals("lemma", res.at("/query/wrap/layer").asText());
Michael Hanl19390652016-01-16 11:01:24 +0100169 }
170
Michael Hanl8abaf9e2016-05-23 16:46:35 +0200171
Michael Hanl19390652016-01-16 11:01:24 +0100172 @Test
Michael Hanl8abaf9e2016-05-23 16:46:35 +0200173 public void testBaseQueryBuild () {
Michael Hanl00b64e02016-05-24 20:24:27 +0200174 KoralCollectionQueryBuilder b = new KoralCollectionQueryBuilder();
175 b.with("(corpusSigle=ADF) | (textClass=freizeit & corpusSigle=WPD)");
176
177 KoralCollectionQueryBuilder c = new KoralCollectionQueryBuilder();
178 c.setBaseQuery(b.toJSON());
179
180 c.with("corpusSigle=BRZ13");
Michael Hanlcb2d3f92016-06-02 17:34:06 +0200181 JsonNode base = (JsonNode) c.rebaseCollection(null);
Michael Hanl00b64e02016-05-24 20:24:27 +0200182 assertNotNull(base);
183 assertEquals(base.at("/collection/@type").asText(), "koral:docGroup");
Michael Hanl00b64e02016-05-24 20:24:27 +0200184 assertEquals(base.at("/collection/operands/1/@type").asText(),
Michael Hanlcedf7212016-05-28 10:43:09 +0200185 "koral:doc");
186 assertEquals(base.at("/collection/operands/1/value").asText(), "BRZ13");
187 assertEquals(base.at("/collection/operands/0/@type").asText(),
Michael Hanl00b64e02016-05-24 20:24:27 +0200188 "koral:docGroup");
Michael Hanlcedf7212016-05-28 10:43:09 +0200189 assertEquals(base.at("/collection/operands/0/operands").size(), 2);
Michael Hanl00b64e02016-05-24 20:24:27 +0200190 }
191
Michael Hanl33829ec2016-05-28 17:03:38 +0200192
Michael Hanl00b64e02016-05-24 20:24:27 +0200193 @Test
Michael Hanl33829ec2016-05-28 17:03:38 +0200194 public void testNodeMergeWithBase () {
Michael Hanl00b64e02016-05-24 20:24:27 +0200195 String coll = "corpusSigle=WPD";
196 String query = "[base=Haus]";
197 QuerySerializer check = new QuerySerializer();
198 check.setQuery(query, "poliqarp");
199 check.setCollection(coll);
200
201 KoralCollectionQueryBuilder b = new KoralCollectionQueryBuilder();
202 b.setBaseQuery(check.toJSON());
203
204 KoralCollectionQueryBuilder test = new KoralCollectionQueryBuilder();
205 test.with("textClass=wissenschaft | textClass=politik");
Michael Hanlcb2d3f92016-06-02 17:34:06 +0200206 JsonNode node = (JsonNode) test.rebaseCollection(null);
Michael Hanl00b64e02016-05-24 20:24:27 +0200207 node = b.mergeWith(node);
208 assertNotNull(node);
209 assertEquals("koral:docGroup", node.at("/collection/@type").asText());
210 assertEquals("operation:and", node.at("/collection/operation").asText());
211 assertEquals(2, node.at("/collection/operands").size());
212 }
213
214
215 @Test
216 public void testStoredCollectionBaseQueryBuild () {
Michael Hanl19390652016-01-16 11:01:24 +0100217
218 }
219
Michael Hanl33829ec2016-05-28 17:03:38 +0200220
Michael Hanlcedf7212016-05-28 10:43:09 +0200221 @Test
Michael Hanl33829ec2016-05-28 17:03:38 +0200222 public void testAddOROperator () {
Michael Hanlcedf7212016-05-28 10:43:09 +0200223 String coll = "corpusSigle=WPD";
224 String query = "[base=Haus]";
225 QuerySerializer check = new QuerySerializer();
226 check.setQuery(query, "poliqarp");
227 check.setCollection(coll);
228
229 KoralCollectionQueryBuilder test = new KoralCollectionQueryBuilder();
230 test.setBaseQuery(check.toJSON());
231 test.or().with("textClass=wissenschaft | textClass=politik");
Michael Hanlcb2d3f92016-06-02 17:34:06 +0200232 JsonNode node = (JsonNode) test.rebaseCollection(null);
Michael Hanlcedf7212016-05-28 10:43:09 +0200233 assertNotNull(node);
234 assertEquals("koral:docGroup", node.at("/collection/@type").asText());
235 assertEquals("operation:or", node.at("/collection/operation").asText());
236 assertEquals(2, node.at("/collection/operands/1/operands").size());
237 }
238
Michael Hanl33829ec2016-05-28 17:03:38 +0200239
Michael Hanlcedf7212016-05-28 10:43:09 +0200240 @Test
Michael Hanl33829ec2016-05-28 17:03:38 +0200241 public void testAddANDOperator () {
Michael Hanlcedf7212016-05-28 10:43:09 +0200242 String coll = "corpusSigle=WPD";
243 String query = "[base=Haus]";
244 QuerySerializer check = new QuerySerializer();
245 check.setQuery(query, "poliqarp");
246 check.setCollection(coll);
247
248 KoralCollectionQueryBuilder test = new KoralCollectionQueryBuilder();
249 test.setBaseQuery(check.toJSON());
250 test.and().with("textClass=wissenschaft | textClass=politik");
Michael Hanlcb2d3f92016-06-02 17:34:06 +0200251 JsonNode node = (JsonNode) test.rebaseCollection(null);
Michael Hanlcedf7212016-05-28 10:43:09 +0200252 assertNotNull(node);
253 assertEquals("koral:docGroup", node.at("/collection/@type").asText());
254 assertEquals("operation:and", node.at("/collection/operation").asText());
255 assertEquals(2, node.at("/collection/operands/1/operands").size());
256 }
257
Michael Hanl33829ec2016-05-28 17:03:38 +0200258
Michael Hanlcedf7212016-05-28 10:43:09 +0200259 @Test
Michael Hanl33829ec2016-05-28 17:03:38 +0200260 public void testAddDefaultOperator () {
Michael Hanlcedf7212016-05-28 10:43:09 +0200261 String coll = "corpusSigle=WPD";
262 String query = "[base=Haus]";
263 QuerySerializer check = new QuerySerializer();
264 check.setQuery(query, "poliqarp");
265 check.setCollection(coll);
266
267 KoralCollectionQueryBuilder test = new KoralCollectionQueryBuilder();
268 test.setBaseQuery(check.toJSON());
269 test.with("textClass=wissenschaft | textClass=politik");
Michael Hanlcb2d3f92016-06-02 17:34:06 +0200270 JsonNode node = (JsonNode) test.rebaseCollection(null);
Michael Hanlcedf7212016-05-28 10:43:09 +0200271 assertNotNull(node);
272 assertEquals("koral:docGroup", node.at("/collection/@type").asText());
273 assertEquals("operation:and", node.at("/collection/operation").asText());
274 assertEquals(2, node.at("/collection/operands/1/operands").size());
275 }
276
Michael Hanl33829ec2016-05-28 17:03:38 +0200277
Michael Hanlcedf7212016-05-28 10:43:09 +0200278 @Test
Michael Hanlcb2d3f92016-06-02 17:34:06 +0200279 public void testCollectionMergeWithFromResource () {
280 KoralCollectionQueryBuilder builder = new KoralCollectionQueryBuilder();
281 builder.with("textClass=politik & corpusSigle=WPD");
282 KustvaktResource resource = new VirtualCollection();
283 resource.setName("collection_1");
284 String json = builder.toJSON();
285 resource.setFields(json);
Michael Hanlcedf7212016-05-28 10:43:09 +0200286
Michael Hanlcb2d3f92016-06-02 17:34:06 +0200287 assertEquals(json, resource.getStringData());
288 builder = new KoralCollectionQueryBuilder();
289 builder.setBaseQuery(resource.getData());
290 builder.or().with("pubPlace=Mannheim");
291 }
Michael Hanlcedf7212016-05-28 10:43:09 +0200292
Michael Hanlcb2d3f92016-06-02 17:34:06 +0200293
294 @Test
295 public void testCollectionMergeFromQuerySerializer () {
296 QuerySerializer s = new QuerySerializer();
297 s.setQuery("[base=Haus]", "poliqarp");
298 KoralCollectionQueryBuilder total = new KoralCollectionQueryBuilder();
299 total.setBaseQuery(s.toJSON());
300
301
302 KoralCollectionQueryBuilder builder = new KoralCollectionQueryBuilder();
303 builder.with("textClass=politik & corpusSigle=WPD");
304 KustvaktResource resource = new VirtualCollection();
305 resource.setName("collection_1");
306 String json = builder.toJSON();
307 resource.setFields(json);
308 // operator is irrelevant here
309 JsonNode node = total.or().mergeWith(resource.getData());
Michael Hanlcedf7212016-05-28 10:43:09 +0200310 assertNotNull(node);
311 assertEquals("koral:docGroup", node.at("/collection/@type").asText());
312 assertEquals("operation:and", node.at("/collection/operation").asText());
Michael Hanlcb2d3f92016-06-02 17:34:06 +0200313 assertEquals("textClass", node.at("/collection/operands/0/key")
314 .asText());
315 assertEquals("corpusSigle", node.at("/collection/operands/1/key")
316 .asText());
Michael Hanlcedf7212016-05-28 10:43:09 +0200317 }
318
Michael Hanlcb2d3f92016-06-02 17:34:06 +0200319
320 @Test
321 public void testBaseCollectionNull () {
322 // base is missing collection segment
323 QuerySerializer s = new QuerySerializer();
324 s.setQuery("[base=Haus]", "poliqarp");
325
326 KoralCollectionQueryBuilder total = new KoralCollectionQueryBuilder();
327 total.setBaseQuery(s.toJSON());
328
329 KoralCollectionQueryBuilder builder = new KoralCollectionQueryBuilder();
330 builder.with("textClass=politik & corpusSigle=WPD");
331 JsonNode node = total.and().mergeWith(
332 (JsonNode) builder.rebaseCollection(null));
333
334 assertNotNull(node);
335 assertEquals("koral:docGroup", node.at("/collection/@type").asText());
336 assertEquals("operation:and", node.at("/collection/operation").asText());
337 assertEquals("koral:doc", node.at("/collection/operands/0/@type")
338 .asText());
339 assertEquals("koral:doc", node.at("/collection/operands/1/@type")
340 .asText());
341 assertEquals("textClass", node.at("/collection/operands/0/key")
342 .asText());
343 assertEquals("corpusSigle", node.at("/collection/operands/1/key")
344 .asText());
345 }
346
347
348 @Test
349 public void testMergeCollectionNull () {
350 // merge json is missing collection segment
351 QuerySerializer s = new QuerySerializer();
352 s.setQuery("[base=Haus]", "poliqarp");
353 s.setCollection("textClass=wissenschaft");
354
355 KoralCollectionQueryBuilder total = new KoralCollectionQueryBuilder();
356 total.setBaseQuery(s.toJSON());
357
358 KoralCollectionQueryBuilder builder = new KoralCollectionQueryBuilder();
359 JsonNode node = total.and().mergeWith(
360 (JsonNode) builder.rebaseCollection(null));
361 assertNotNull(node);
362 assertEquals("koral:doc", node.at("/collection/@type").asText());
363 assertEquals("textClass", node.at("/collection/key").asText());
364 }
365
366
Michael Hanlfb839b92015-09-19 21:32:34 +0200367}