Merged V3.1 to HEAD

13256: Fix ETHREEOH-1221   Hard-coded use of "admin" username
   ___________________________________________________________________
   Modified: svn:mergeinfo
      Merged /alfresco/BRANCHES/V3.1:r13256


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@13613 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Derek Hulley
2009-03-12 21:48:15 +00:00
parent 78dea7096a
commit 66a8e117e1
14 changed files with 70 additions and 55 deletions

View File

@@ -67,6 +67,14 @@ public class TestWebScriptRepoServer extends TestWebScriptServer
}
/**
* Get default user name
*/
protected String getDefaultUserName()
{
return AuthenticationUtil.getAdminUserName();
}
/**
* Main entry point.
*/
public static void main(String[] args)
@@ -91,12 +99,12 @@ public class TestWebScriptRepoServer extends TestWebScriptServer
}
private final static String[] CONFIG_LOCATIONS = new String[]
{
"classpath:alfresco/application-context.xml",
"classpath:alfresco/webscript-framework-application-context.xml",
"classpath:alfresco/web-scripts-application-context.xml",
"classpath:alfresco/web-scripts-application-context-test.xml"
};
{
"classpath:alfresco/application-context.xml",
"classpath:alfresco/webscript-framework-application-context.xml",
"classpath:alfresco/web-scripts-application-context.xml",
"classpath:alfresco/web-scripts-application-context-test.xml"
};
/**
* Retrieve an instance of the TestWebScriptServer
@@ -155,7 +163,7 @@ public class TestWebScriptRepoServer extends TestWebScriptServer
}
catch(AuthenticationException e)
{
executeCommand("user admin");
executeCommand("user " + getDefaultUserName());
}
// execute command in context of currently selected user