### Question:
AddChangeRecordEntry extends ChangeRecordEntry { public List<Attribute> getAttributes() { return Collections.unmodifiableList(attributes); } AddChangeRecordEntry(DN dn,
      Map<AttributeType,List<Attribute>> attributes); ChangeOperationType getChangeOperationType(); List<Attribute> getAttributes(); @Override String toString();  }### Answer:
@Test public void testGetAttributesEmpty() throws Exception { Map<AttributeType, List<Attribute>> empty = Collections.emptyMap(); AddChangeRecordEntry entry = new AddChangeRecordEntry(DN.rootDN(), empty); List<Attribute> attrs = entry.getAttributes(); Assert.assertEquals(attrs.size(), 0); }
@Test public void testGetAttributesNonEmpty() throws Exception { AddChangeRecordEntry entry = new AddChangeRecordEntry(DN.rootDN(), attributes); List<Attribute> attrs = entry.getAttributes(); Assert.assertEquals(attrs.size(), 1); Attribute first = attrs.get(0); Assert.assertEquals(first, attribute); }