//create the /db/securityTest2/test.xml resource
Resource resource = test.createResource("test.xml", XMLResource.RESOURCE_TYPE);
resource.setContent("<test/>");
test.storeResource(resource);
ums.chgrp(resource, "extusers");
//create /db/securityTest2/parentCollection with owner "test1:users" and mode "rwxrwsrwx"
Collection parentCollection = cms.createCollection("parentCollection");
ums = (UserManagementService)parentCollection.getService("UserManagementService", "1.0");
ums.chmod("rwxrwsrwx");