### Question:
StringReportCellCSVExporter implements ReportCellCSVExporter { @Override public String getValue(Object result) { Resource resource = (Resource) result; ReportCellValue val = new ReportCellValue(resource, property); List<String> values = new ArrayList<>(); if (val.getValue() != null) { if (val.isArray()) { for (String value : val.getMultipleValues()) { values.add(value); } } else { values.add(val.getSingleValue()); } } if (StringUtils.isNotBlank(format)) { for (int i = 0; i < values.size(); i++) { values.set(i, String.format(format, values.get(i))); } } return StringUtils.join(values, ";"); }  @Override String getValue(Object result);  }### Answer:
@Test public void testMultiple() throws IllegalAccessException { log.info("testMultiple"); StringReportCellCSVExporter exporter = new StringReportCellCSVExporter(); FieldUtils.writeField(exporter, "property", "multiple", true); assertEquals(StringUtils.join(ARRAY_VALUE, ";"), exporter.getValue(mockResource)); log.info("Test successful!"); }
@Test public void testNotFound() throws IllegalAccessException { log.info("testNotFound"); StringReportCellCSVExporter exporter = new StringReportCellCSVExporter(); FieldUtils.writeField(exporter, "property", "somethingelse", true); assertEquals("", exporter.getValue(mockResource)); log.info("Test successful!"); }
@Test public void testSingle() throws IllegalAccessException { log.info("testSingle"); StringReportCellCSVExporter exporter = new StringReportCellCSVExporter(); FieldUtils.writeField(exporter, "property", "single", true); assertEquals(ARRAY_VALUE[0], exporter.getValue(mockResource)); log.info("Test successful!"); }