Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
titleCreateMockContentFromPropertiesFile.java
HierarchyManagerSession hmsession = MockUtilSessionTestUtil.createAndSetHierarchyManagercreateSession(ContentRepositoryRepositoryConstants.USERS, getClass().getResourceAsStream("sample.properties"));

...

Code Block
titleCreateMockContentFromString.java
final String CONTENTcontent = StringUtils.join(Arrays.asList(
    "main/content@type=mgnl:contentNode",
    "main/content@uuid=4",
    "main/content.value=Content Value"
    ), "\n");

HierarchyManagerSession hmsession = MockUtilSessionTestUtil.createAndSetHierarchyManagercreateSession(ContentRepositoryRepositoryConstants.USERS, CONTENTcontent);

You may also directly instantiate a MockContent and then add the child Contents and or NodeData's as required

...