AMJournalEditorConfigContributor extends BaseEditorConfigContributor { protected void addAMImageFileEntryItemSelectorReturnType( ItemSelectorCriterion itemSelectorCriterion) { List<ItemSelectorReturnType> desiredItemSelectorReturnTypes = itemSelectorCriterion.getDesiredItemSelectorReturnTypes(); desiredItemSelectorReturnTypes.add( new AMImageFileEntryItemSelectorReturnType()); }  @Override void populateConfigJSONObject(
		JSONObject jsonObject, Map<String, Object> inputEditorTaglibAttributes,
		ThemeDisplay themeDisplay,
		RequestBackedPortletURLFactory requestBackedPortletURLFactory);  }
@Test public void testAddAMImageFileEntryItemSelectorReturnType() { AMJournalEditorConfigContributor amJournalEditorConfigContributor = new AMJournalEditorConfigContributor(); JournalItemSelectorCriterion journalItemSelectorCriterion = new JournalItemSelectorCriterion(); journalItemSelectorCriterion.setDesiredItemSelectorReturnTypes( new FileEntryItemSelectorReturnType()); amJournalEditorConfigContributor. addAMImageFileEntryItemSelectorReturnType( journalItemSelectorCriterion); List<ItemSelectorReturnType> desiredItemSelectorReturnTypes = journalItemSelectorCriterion.getDesiredItemSelectorReturnTypes(); Assert.assertEquals( desiredItemSelectorReturnTypes.toString(), 2, desiredItemSelectorReturnTypes.size()); _assertContains( desiredItemSelectorReturnTypes, itemSelectorReturnType -> itemSelectorReturnType instanceof AMImageFileEntryItemSelectorReturnType); _assertContains( desiredItemSelectorReturnTypes, itemSelectorReturnType -> itemSelectorReturnType instanceof FileEntryItemSelectorReturnType); }