Source:
<code>protected void testBulkLifeCycleChangeTwoLevels() { DocumentModel folderDoc1 = session.createDocumentModel("/", "testFolder1", "Folder"); folderDoc1 = session.createDocument(folderDoc1); <START> DocumentModel folderDoc2 = session.createDocumentModel(folderDoc1.getPathAsString(), "testFolder2", "Folder"); <END> folderDoc2 = session.createDocument(folderDoc2); DocumentModel testFile1 = session.createDocumentModel(folderDoc2.getPathAsString(), "testFile1", "File"); testFile1 = session.createDocument(testFile1); DocumentModel testFile2 = session.createDocumentModel(folderDoc2.getPathAsString(), "testFile2", "File"); testFile2 = session.createDocument(testFile2); DocumentModel testFile3 = session.createDocumentModel(folderDoc2.getPathAsString(), "testFile3", "File"); testFile3 = session.createDocument(testFile3); session.saveDocument(folderDoc1); session.saveDocument(folderDoc2); session.saveDocument(testFile1); session.saveDocument(testFile2); session.saveDocument(testFile3); Collection<String> allowedStateTransitions = session.getAllowedStateTransitions(folderDoc1.getRef()); assertTrue(allowedStateTransitions.contains("approve")); assertTrue(session.followTransition(folderDoc1.getRef(), "approve")); session.save(); nextTransaction(); assertEquals("approved", session.getCurrentLifeCycleState(folderDoc2.getRef())); assertEquals("approved", session.getCurrentLifeCycleState(testFile1.getRef())); assertEquals("approved", session.getCurrentLifeCycleState(testFile2.getRef())); assertEquals("approved", session.getCurrentLifeCycleState(testFile3.getRef())); }</code><technical_language>revert of explicit paths</technical_language>

Target:
protected void testBulkLifeCycleChangeTwoLevels() { DocumentModel folderDoc1 = session.createDocumentModel("/", "testFolder1", "Folder"); folderDoc1 = session.createDocument(folderDoc1); DocumentModel folderDoc2 = session.createDocumentModel("/testFolder1", "testFolder2", "Folder"); folderDoc2 = session.createDocument(folderDoc2); DocumentModel testFile1 = session.createDocumentModel("/testFolder1/testFolder2", "testFile1", "File"); testFile1 = session.createDocument(testFile1); DocumentModel testFile2 = session.createDocumentModel("/testFolder1/testFolder2", "testFile2", "File"); testFile2 = session.createDocument(testFile2); DocumentModel testFile3 = session.createDocumentModel("/testFolder1/testFolder2", "testFile3", "File"); testFile3 = session.createDocument(testFile3); session.saveDocument(folderDoc1); session.saveDocument(folderDoc2); session.saveDocument(testFile1); session.saveDocument(testFile2); session.saveDocument(testFile3); Collection<String> allowedStateTransitions = session.getAllowedStateTransitions(folderDoc1.getRef()); assertTrue(allowedStateTransitions.contains("approve")); assertTrue(session.followTransition(folderDoc1.getRef(), "approve")); session.save(); nextTransaction(); assertEquals("approved", session.getCurrentLifeCycleState(folderDoc2.getRef())); assertEquals("approved", session.getCurrentLifeCycleState(testFile1.getRef())); assertEquals("approved", session.getCurrentLifeCycleState(testFile2.getRef())); assertEquals("approved", session.getCurrentLifeCycleState(testFile3.getRef())); }