Merged HEAD-BUG-FIX (4.3/Cloud) to HEAD (4.3/Cloud)

59886: Merged V4.2-BUG-FIX (4.2.2) to HEAD-BUG-FIX (Cloud/4.3)
      59621: Merged DEV to V4.2-BUG-FIX
         58258: MNT-10038 : CIFS and FTP accessing repo without transactions for MNT-9806
         58307: MNT-10038 - MNT-9806 Corrected transaction test error in ContentDiskDriverTest


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@62203 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Alan Davis
2014-02-12 08:15:52 +00:00
parent 3288e9dc06
commit dbcef62a9c
5 changed files with 146 additions and 18 deletions

View File

@@ -842,18 +842,28 @@ public class ContentDiskDriverTest extends TestCase
* Step 5: Rename to another directory
*/
String DIR_NEW_PATH = TEST_ROOT_DOS_PATH + "\\NewDir";
String NEW_PATH = DIR_NEW_PATH + "\\File2";
final String NEW_PATH = DIR_NEW_PATH + "\\File2";
FileOpenParams params5 = new FileOpenParams(DIR_NEW_PATH, 0, AccessMode.ReadWrite, FileAttribute.NTNormal, 0);
driver.createDirectory(testSession, testConnection, params5);
NodeRef newDirNodeRef = getNodeForPath(testConnection, DIR_NEW_PATH);
final NodeRef newDirNodeRef = getNodeForPath(testConnection, DIR_NEW_PATH);
driver.renameFile(testSession, testConnection, FILE_PATH2, NEW_PATH);
NodeRef file5NodeRef = getNodeForPath(testConnection, NEW_PATH);
ChildAssociationRef parentRef5 = nodeService.getPrimaryParent(file5NodeRef);
assertTrue(parentRef5.getParentRef().equals(newDirNodeRef));
RetryingTransactionCallback<Void> validateStep5CB = new RetryingTransactionCallback<Void>() {
@Override
public Void execute() throws Throwable
{
NodeRef file5NodeRef = getNodeForPath(testConnection, NEW_PATH);
ChildAssociationRef parentRef5 = nodeService.getPrimaryParent(file5NodeRef);
assertTrue(parentRef5.getParentRef().equals(newDirNodeRef));
return null;
}
};
tran.doInTransaction(validateStep5CB, false, true);
// /**
// * Step 5: rename to self - check no damage.