@Test
public void testGetMetaInformation() {
layerInfoTileLayer = new GeoServerTileLayer(layerInfo, defaults, gridSetBroker);
layerGroupInfoTileLayer = new GeoServerTileLayer(layerGroup, defaults, gridSetBroker);
LayerMetaInformation metaInformation = layerInfoTileLayer.getMetaInformation();
assertNotNull(metaInformation);
String title = metaInformation.getTitle();
String description = metaInformation.getDescription();
List<String> keywords = metaInformation.getKeywords();
assertEquals(layerInfo.getResource().getTitle(), title);
assertEquals(layerInfo.getResource().getAbstract(), description);
assertEquals(layerInfo.getResource().getKeywords().size(), keywords.size());
for (String kw : keywords) {
assertTrue(layerInfo.getResource().getKeywords().contains(new Keyword(kw)));
}
metaInformation = layerGroupInfoTileLayer.getMetaInformation();
assertNotNull(metaInformation);
title = metaInformation.getTitle();
description = metaInformation.getDescription();
keywords = metaInformation.getKeywords();
// these properties are missing from LayerGroupInfo interface
assertEquals("Group title", title);
assertEquals("Group abstract", description);
assertEquals(0, keywords.size());