### Question:
RuleFlowGroupQueryService { @SuppressWarnings("unchecked") private static RuleFlowGroup getValue(final RefactoringPageRow row) { Map<String, String> values = (Map<String, String>) row.getValue(); String name = values.get("name"); if (StringUtils.isEmpty(name)) { return null; } RuleFlowGroup group = new RuleFlowGroup(name); group.setFileName(values.get("filename")); group.setPathUri(values.get("pathuri")); return group; } RuleFlowGroupQueryService(); @Inject  RuleFlowGroupQueryService(final RefactoringQueryService queryService);   RuleFlowGroupQueryService(final RefactoringQueryService queryService,
                              final Function<List<RefactoringPageRow>, List<RuleFlowGroup>> resultToSelectorData); List<RuleFlowGroup> getRuleFlowGroupNames(); static final Function<List<RefactoringPageRow>, List<RuleFlowGroup>> DEFAULT_RESULT_CONVERTER; }### Answer:
@Test @SuppressWarnings("unchecked") public void testDefaultResultConverter() { RefactoringPageRow row1 = mock(RefactoringPageRow.class); when(row1.getValue()).thenReturn(asMap("row1")); RefactoringPageRow row2 = mock(RefactoringPageRow.class); when(row2.getValue()).thenReturn(asMap("row2")); RefactoringPageRow row3 = mock(RefactoringPageRow.class); when(row3.getValue()).thenReturn(asMap("row3")); RefactoringPageRow row4 = mock(RefactoringPageRow.class); when(row4.getValue()).thenReturn(asMap("row4")); RefactoringPageRow row4_2 = mock(RefactoringPageRow.class); when(row4_2.getValue()).thenReturn(asMap("row4")); RefactoringPageRow emptyRow1 = mock(RefactoringPageRow.class); when(emptyRow1.getValue()).thenReturn(asMap("")); RefactoringPageRow emptyRow2 = mock(RefactoringPageRow.class); when(emptyRow2.getValue()).thenReturn(asMap("")); List<RefactoringPageRow> rows = Arrays.asList(row1, row2, row3, row4, row4_2, emptyRow1, emptyRow2); List<RuleFlowGroup> result = RuleFlowGroupQueryService.DEFAULT_RESULT_CONVERTER.apply(rows); assertEquals(5, result.size()); RuleFlowGroup group1 = new RuleFlowGroup("row1"); RuleFlowGroup group2 = new RuleFlowGroup("row2"); RuleFlowGroup group3 = new RuleFlowGroup("row3"); RuleFlowGroup group4 = new RuleFlowGroup("row4"); assertTrue(result.contains(group1)); assertTrue(result.contains(group2)); assertTrue(result.contains(group3)); assertTrue(result.contains(group4)); }