contentStream, versioningState, policies, addACEs, removeACEs, null);
assertNotNull(objectId);
assertTrue(existsObject(objectId));
if (folderId != null) {
ObjectInFolderData folderChild = getChild(folderId, objectId);
// check canGetProperties
assertAllowableAction(folderChild.getObject().getAllowableActions(), Action.CAN_GET_PROPERTIES, true);
// check canGetContentStream
if (contentStream != null) {
assertAllowableAction(folderChild.getObject().getAllowableActions(), Action.CAN_GET_CONTENT_STREAM,
true);
}
// check name
PropertyData<?> nameProp = properties.getProperties().get(PropertyIds.NAME);
if (nameProp != null) {
assertPropertyValue(folderChild.getObject().getProperties(), PropertyIds.NAME, PropertyString.class,
nameProp.getFirstValue());
}
// check object type
PropertyData<?> typeProp = properties.getProperties().get(PropertyIds.OBJECT_TYPE_ID);
assertNotNull(typeProp);
assertPropertyValue(folderChild.getObject().getProperties(), PropertyIds.OBJECT_TYPE_ID, PropertyId.class,
typeProp.getFirstValue());
// check parent
List<ObjectParentData> parents = getBinding().getNavigationService().getObjectParents(
getTestRepositoryId(), objectId, "*", Boolean.TRUE, IncludeRelationships.BOTH, null, Boolean.TRUE,
null);
assertNotNull(parents);
assertEquals(1, parents.size());
ObjectParentData parent = parents.get(0);
assertNotNull(parent);
assertNotNull(parent.getRelativePathSegment());
assertNotNull(parent.getObject());
assertNotNull(parent.getObject().getProperties().getProperties());
assertNotNull(parent.getObject().getProperties().getProperties().get(PropertyIds.OBJECT_ID));
assertEquals(folderId, parent.getObject().getProperties().getProperties().get(PropertyIds.OBJECT_ID)
.getFirstValue());
// get document by path (check relative path segment)
assertNotNull(parent.getObject().getProperties().getProperties().get(PropertyIds.PATH));
String parentPath = parent.getObject().getProperties().getProperties().get(PropertyIds.PATH)
.getFirstValue().toString();
ObjectData docByPath = getObjectByPath((parentPath.equals("/") ? "" : parentPath) + "/"
+ folderChild.getPathSegment());
PropertyData<?> idProp = docByPath.getProperties().getProperties().get(PropertyIds.OBJECT_ID);
assertNotNull(idProp);
assertEquals(objectId, idProp.getFirstValue());
} else {