assertEquals(first + 3, manager.nextId());
}
@Test
public void testInsertObjectWithFields() throws ObjectPersistenceException {
final ObjectData data = createData(Role.class, 99, FileVersion.create("user", 13));
data.set("Person", RootOidDefault.create(ObjectSpecId.of("RLE"), ""+101));
assertNotNull(data.get("Person"));
data.set("Name", "Harry");
assertNotNull(data.get("Name"));
manager.insertObject(data);
final ObjectData read = (ObjectData) manager.loadData(data.getRootOid());
assertEquals(data.getRootOid(), read.getRootOid());
assertEquals(data.getObjectSpecId(), read.getObjectSpecId());
assertEquals(data.get("Person"), read.get("Person"));
assertEquals(data.get("Name"), read.get("Name"));
}