mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-24 17:32:48 +00:00
Alfresco->Alfresco deployment understands exclusions.
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@6228 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -475,16 +475,19 @@ public class AVMServiceTest extends AVMServiceTestBase
|
||||
try
|
||||
{
|
||||
DeploymentService depService = (DeploymentService) fContext.getBean("DeploymentService");
|
||||
NameMatcher matcher = (NameMatcher)fContext.getBean("globalPathExcluder");
|
||||
setupBasicTree();
|
||||
fService.addAspect("main:/a", ContentModel.ASPECT_REFERENCEABLE);
|
||||
fService.addAspect("main:/a/b", ContentModel.ASPECT_REFERENCEABLE);
|
||||
fService.addAspect("main:/a/b/c", ContentModel.ASPECT_REFERENCEABLE);
|
||||
fService.addAspect("main:/a/b/c/foo", ContentModel.ASPECT_REFERENCEABLE);
|
||||
fService.addAspect("main:/a/b/c/bar", ContentModel.ASPECT_REFERENCEABLE);
|
||||
fService.createFile("main:/a/b", "snarl.bak").close();
|
||||
// TestDeploymentCallback callback = new TestDeploymentCallback();
|
||||
fService.createStore("target");
|
||||
DeploymentReport report = depService.deployDifference(-1, "main:/a", "localhost", 50500, "admin", "admin",
|
||||
"target:/a", null, false, false, false, null);
|
||||
"target:/a", matcher, false, false, false, null);
|
||||
assertNull(fService.lookup(-1, "target:/a/b/snarl.bak"));
|
||||
runQueriesAgainstBasicTreeWithAOnly("target");
|
||||
System.out.println(report);
|
||||
assertEquals(fService.lookup(-1, "main:/a/b/c/foo").getGuid(), fService.lookup(-1, "target:/a/b/c/foo")
|
||||
@@ -495,39 +498,39 @@ public class AVMServiceTest extends AVMServiceTestBase
|
||||
ContentData dstCD = fService.getContentDataForRead(-1, "target:/a/b/c/foo");
|
||||
assertEquals(srcCD.getMimetype(), dstCD.getMimetype());
|
||||
fService.createFile("main:/a/b", "biz").close();
|
||||
report = depService.deployDifference(-1, "main:/a", "localhost", 50500, "admin", "admin", "target:/a", null,
|
||||
report = depService.deployDifference(-1, "main:/a", "localhost", 50500, "admin", "admin", "target:/a", matcher,
|
||||
false, false, true, null);
|
||||
// Nothing was done
|
||||
runQueriesAgainstBasicTreeWithAOnly("target");
|
||||
System.out.println(report);
|
||||
System.out.println(recursiveList("target", -1, true));
|
||||
assertNull(fService.lookup(-1, "target:/a/b/biz"));
|
||||
report = depService.deployDifference(-1, "main:/a", "localhost", 50500, "admin", "admin", "target:/a", null,
|
||||
report = depService.deployDifference(-1, "main:/a", "localhost", 50500, "admin", "admin", "target:/a", matcher,
|
||||
false, false, false, null);
|
||||
System.out.println(report);
|
||||
runQueriesForCreateAndDeploy("target");
|
||||
assertEquals(fService.lookup(-1, "main:/a/b/biz").getGuid(), fService.lookup(-1, "target:/a/b/biz")
|
||||
.getGuid());
|
||||
fService.removeNode("main:/a/b/c/foo");
|
||||
report = depService.deployDifference(-1, "main:/a", "localhost", 50500, "admin", "admin", "target:/a", null,
|
||||
report = depService.deployDifference(-1, "main:/a", "localhost", 50500, "admin", "admin", "target:/a", matcher,
|
||||
false, true, false, null);
|
||||
runQueriesForCreateAndDeploy("target");
|
||||
System.out.println(report);
|
||||
assertNotNull(fService.lookup(-1, "target:/a/b/c/foo"));
|
||||
report = depService.deployDifference(-1, "main:/a", "localhost", 50500, "admin", "admin", "target:/a", null,
|
||||
report = depService.deployDifference(-1, "main:/a", "localhost", 50500, "admin", "admin", "target:/a", matcher,
|
||||
false, false, false, null);
|
||||
System.out.println(report);
|
||||
runQueriesForRemoveAndDelpoy("target");
|
||||
assertNull(fService.lookup(-1, "target:/a/b/c/foo"));
|
||||
fService.removeNode("main:/a/b/c/bar");
|
||||
fService.createDirectory("main:/a/b/c", "bar");
|
||||
report = depService.deployDifference(-1, "main:/a", "localhost", 50500, "admin", "admin", "target:/a", null,
|
||||
report = depService.deployDifference(-1, "main:/a", "localhost", 50500, "admin", "admin", "target:/a", matcher,
|
||||
false, false, false, null);
|
||||
System.out.println(report);
|
||||
runQueriesForRemoveFileAndCreateDirectoryAndDeploy("target");
|
||||
report = depService.deployDifference(-1, "main:/a", "localhost", 50500, "admin", "admin", "target:/a", null,
|
||||
report = depService.deployDifference(-1, "main:/a", "localhost", 50500, "admin", "admin", "target:/a", matcher,
|
||||
false, false, false, null);
|
||||
depService.deployDifference(-1, "main:/a", "localhost", 50500, "admin", "admin", "target2:/wiggly/diggly", null,
|
||||
depService.deployDifference(-1, "main:/a", "localhost", 50500, "admin", "admin", "target2:/wiggly/diggly", matcher,
|
||||
true, false, false, null);
|
||||
System.out.println(report);
|
||||
}
|
||||
|
Reference in New Issue
Block a user