Editor { public List<Item> getItems() { return Collections.unmodifiableList(items); }  List<Item> getItems(); Resource getContainer();  }
@Test void testGetItems() { Editor childrenEditor = getItemsEditor(CAROUSEL_PATH); List<Item> items = childrenEditor.getItems(); assertEquals(5, items.size(), "Number of items is not the same."); Object[][] expectedItems = { {"item_1", "Teaser 1", "Teaser (v1)", "image", null, null}, {"item_2", "Teaser 2", "Teaser Icon Abbreviation", null, null, "Aa"}, {"item_3", "Teaser 3", "Teaser Icon Auto Abbreviation", null, null, "Te"}, {"item_4", "Teaser 4", "Teaser Icon SVG", null, "/apps/core/wcm/components/teaserIconSVG/cq:icon.svg", null}, {"item_5", "Teaser 5", "Teaser Icon PNG", null, "/apps/core/wcm/components/teaserIconPNG/cq:icon.png", null} }; int index = 0; for (Item item : items) { assertEquals(expectedItems[index][0], item.getName(), "Item name does not match the expected."); assertEquals(expectedItems[index][1], item.getValue(), "Item value does not match the expected."); assertEquals(expectedItems[index][2], item.getTitle(), "Item title does not match the expected."); assertEquals(expectedItems[index][3], item.getIconName(), "Item icon name does not match the expected."); assertEquals(expectedItems[index][4], item.getIconPath(), "Item icon path does not match the expected."); assertEquals(expectedItems[index][5], item.getIconAbbreviation(), "Item icon abbreviation does not match the expected."); index++; } }