mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-14 17:58:59 +00:00
Merged 5.2.N (5.2.1) to HEAD (5.2)
129187 mmuller: Merged RETURN-OF-THE-API (5.2.0) to 5.2.N (5.2.1) 129004 adavis: REPO-243 People Live Search - First cut of this code - Includes a re-factor of the code used by GET /queries/live-search-nodes as there is much in common. - Still have some tests to write and there are bound to be comments from the review. git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@129361 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -45,6 +45,7 @@ import org.alfresco.rest.api.tests.client.PublicApiClient;
|
||||
import org.alfresco.rest.api.tests.client.PublicApiHttpClient.BinaryPayload;
|
||||
import org.alfresco.rest.api.tests.client.PublicApiHttpClient.RequestBuilder;
|
||||
import org.alfresco.rest.api.tests.client.RequestContext;
|
||||
import org.alfresco.rest.api.tests.client.data.Company;
|
||||
import org.alfresco.rest.api.tests.client.data.ContentInfo;
|
||||
import org.alfresco.rest.api.tests.client.data.Document;
|
||||
import org.alfresco.rest.api.tests.client.data.Folder;
|
||||
@@ -452,10 +453,15 @@ public abstract class AbstractBaseApiTest extends EnterpriseTestApi
|
||||
return createUser(username, "password", null);
|
||||
}
|
||||
|
||||
protected String createUser(String usernameIn, String password, TestNetwork network)
|
||||
{
|
||||
return createUser(new PersonInfo(usernameIn, usernameIn, usernameIn, password, null, null, null, null, null, null, null), network);
|
||||
}
|
||||
|
||||
/**
|
||||
* TODO implement as remote api call
|
||||
*/
|
||||
protected String createUser(final String usernameIn, final String password, final TestNetwork network)
|
||||
protected String createUser(final PersonInfo personInfo, final TestNetwork network)
|
||||
{
|
||||
final String tenantDomain = (network != null ? network.getId() : TenantService.DEFAULT_DOMAIN);
|
||||
|
||||
@@ -468,8 +474,8 @@ public abstract class AbstractBaseApiTest extends EnterpriseTestApi
|
||||
{
|
||||
public String doWork() throws Exception
|
||||
{
|
||||
String username = repoService.getPublicApiContext().createUserName(usernameIn, tenantDomain);
|
||||
PersonInfo personInfo = new PersonInfo(username, username, username, password, null, null, null, null, null, null, null);
|
||||
String username = repoService.getPublicApiContext().createUserName(personInfo.getUsername(), tenantDomain);
|
||||
personInfo.setUsername(username);
|
||||
RepoService.TestPerson person = repoService.createUser(personInfo, username, network);
|
||||
return person.getId();
|
||||
|
||||
|
Reference in New Issue
Block a user