### Question:
MarkRowsAnalyzerResultReducer implements AnalyzerResultReducer<MarkRowsAnalyzerResult> { @Override public MarkRowsAnalyzerResult reduce(Collection<? extends MarkRowsAnalyzerResult> results) { InputColumn<?>[] highlightedColumns = null; final RowAnnotationImpl annotation = new RowAnnotationImpl(); for (MarkRowsAnalyzerResult result : results) { final int annotatedRowCount = result.getAnnotatedRowCount(); annotation.incrementRowCount(annotatedRowCount); if (highlightedColumns == null || highlightedColumns.length == 0) { highlightedColumns = result.getHighlightedColumns(); } } return new MarkRowsAnalyzerResult(annotation, null, highlightedColumns); }  @Override MarkRowsAnalyzerResult reduce(Collection<? extends MarkRowsAnalyzerResult> results);  }### Answer:
@Test public void testReduceNone() throws Exception { final MarkRowsAnalyzerResult result = reducer.reduce(Collections.emptyList()); assertEquals(0, result.getTotalRowCount()); assertTrue(result.getSampleRows().isEmpty()); }
@Test public void testReduceSums() throws Exception { final MarkRowsAnalyzerResult result1 = createResult(); final MarkRowsAnalyzerResult result2 = createResult(); final MarkRowsAnalyzerResult result = reducer.reduce(Arrays.asList(result1, result2)); assertEquals(2, result.getAnnotatedRowCount()); assertTrue(result.getSampleRows().isEmpty()); }