### Question:
TagReportCellCSVExporter implements ReportCellCSVExporter { @Override public String getValue(Object result) { Resource resource = (Resource) result; TagManager tagMgr = resource.getResourceResolver().adaptTo(TagManager.class); log.debug("Loading tags from {}@{}", resource.getPath(), property); List<String> tags = new ArrayList<>(); String[] values = resource.getValueMap().get(property, String[].class); if (values != null) { for (String value : values) { tags.add(Optional.ofNullable(tagMgr).map(tm -> tm.resolve(value).getTitle()).orElse(value)); } } log.debug("Loaded {} tags", tags); return StringUtils.join(tags, ";"); }  @Override String getValue(Object result);  }### Answer:
@Test public void testEmpty() throws IllegalAccessException { log.info("testEmpty"); TagReportCellCSVExporter exporter = new TagReportCellCSVExporter(); FieldUtils.writeField(exporter, "property", "tags2", true); assertEquals("", exporter.getValue(mockResource)); log.info("Test successful!"); }
@Test public void testExporter() throws IllegalAccessException { log.info("testExporter"); TagReportCellCSVExporter exporter = new TagReportCellCSVExporter(); FieldUtils.writeField(exporter, "property", "tags", true); assertEquals(StringUtils.join(TAGS_VALUE, ";"), exporter.getValue(mockResource)); log.info("Test successful!"); }