### Question:
ListComboBoxModel extends AbstractListModel<E> implements MutableComboBoxModel<E> { @Override public void addElement(E anObject) { myObjects.add(anObject); fireIntervalAdded(this, myObjects.size() - 1, myObjects.size() - 1); if (myObjects.size() == 1 && mySelectedObject == null && anObject != null) { setSelectedElement(anObject); } } ListComboBoxModel(); @SafeVarargs @SuppressWarnings({ "varargs", "PMD.ConstructorCallsOverridableMethod" })  ListComboBoxModel(E... items); @SuppressWarnings("PMD.ConstructorCallsOverridableMethod")  ListComboBoxModel(Collection<? extends E> items); private  ListComboBoxModel(List<E> items); @SuppressWarnings("unchecked") @Override @Deprecated void setSelectedItem(Object anObject); void setSelectedElement(E anObject); @Override E getSelectedItem(); @Override int getSize(); @Override E getElementAt(int index); int getIndexOf(Object anObject); @Override void addElement(E anObject); @Override void insertElementAt(E anObject, int index); @Override void removeElementAt(int index); @Override void removeElement(Object anObject); void removeAllElements();  }### Answer:
@Test public void testAddElement() { List<Integer> list = Arrays.asList(Integer.valueOf(0), Integer.valueOf(1), Integer.valueOf(2)); ListComboBoxModel<Integer> model = new ListComboBoxModel<>(list); ListDataListener listener = EasyMock.createMock(ListDataListener.class); listener.intervalAdded(eqEvent(new ListDataEvent(this, ListDataEvent.INTERVAL_ADDED, 3, 3))); EasyMock.replay(listener); model.addListDataListener(listener); model.addElement(Integer.valueOf(3)); Assert.assertEquals(Integer.valueOf(3), model.getElementAt(3)); EasyMock.verify(listener); }