### Question:
DataModel implements DataModelIF<U, I> { @Override public int getNumItems() { return items.size(); } DataModel(); protected  DataModel(final boolean ignoreDupPreferences); protected  DataModel(final boolean ignoreDupPreferences, final Map<U, Map<I, Double>> userItemPreference, final Set<I> itemSet); @Override Double getUserItemPreference(U u, I i); @Override Iterable<I> getUserItems(U u); @Override void addPreference(final U u, final I i, final Double d); @Override Iterable<I> getItems(); @Override Iterable<U> getUsers(); @Override int getNumItems(); @Override int getNumUsers(); @Override void clear();  }### Answer:
@Test public void testGetNumItems() { assertEquals(ITEMS, dm.getNumItems()); }