### Question:
Qualifier { public Map<String, Object> getSnapshot() { Map<String, Object> idSnapshot = row.getChangeId().getIdSnapshot(); if(additionalQualifier == null || additionalQualifier.isEmpty()) { return idSnapshot; } Map<String, Object> qualifier = new HashMap<>(additionalQualifier.size() + idSnapshot.size()); AtomicBoolean hasPK = new AtomicBoolean(!idSnapshot.isEmpty()); idSnapshot.forEach((attr, value) -> { if(value != null) { qualifier.put(attr, value); } else { hasPK.set(false); } }); if(!hasPK.get() || optimisticLock) { additionalQualifier.forEach((attr, value) -> qualifier.put(attr.getName(), value) ); } return qualifier; } protected  Qualifier(DbRowOp row); Map<String, Object> getSnapshot(); List<DbAttribute> getQualifierAttributes(); Collection<String> getNullQualifierNames(); void addAdditionalQualifier(DbAttribute dbAttribute, Object value); void addAdditionalQualifier(DbAttribute dbAttribute, Object value, boolean optimisticLock); boolean isUsingOptimisticLocking(); boolean isSameBatch(Qualifier other);  }### Answer:
@Test public void testMapObjectIdQualifier() { Map<String, Object> idMap = new HashMap<>(); idMap.put("id1", 123); idMap.put("id2", 321); ObjectId id = ObjectId.of("test", idMap); Persistent persistent = mockObject(id); DbRowOp row = mockRow(persistent); Qualifier qualifier = new Qualifier(row); Map<String, Object> qualifierSnapshot = qualifier.getSnapshot(); assertEquals(idMap, qualifierSnapshot); qualifierSnapshot = qualifier.getSnapshot(); assertEquals(idMap, qualifierSnapshot); }