Merged DEV/CMIS0_61 to HEAD (final part)

14168 Minor fixes for issues found at CMIS PlugFest:
  - test framework: allow remote requests without authentication headers
  - test framework: validate requests toggle was not working; always treated as true
  - web services: expose root document, folder, policy and relationship types in getTypeDefinitions()

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@14178 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
David Caruana
2009-05-01 21:33:09 +00:00
parent a8603091e9
commit 46661c29d4
5 changed files with 14 additions and 15 deletions

View File

@@ -230,7 +230,10 @@ public abstract class BaseWebScriptTest extends TestCase
{
httpClient = new HttpClient();
httpClient.getParams().setBooleanParameter(HttpClientParams.PREEMPTIVE_AUTHENTICATION, true);
httpClient.getState().setCredentials(new AuthScope(AuthScope.ANY_HOST, AuthScope.ANY_PORT), new UsernamePasswordCredentials(remoteServer.username, remoteServer.password));
if (remoteServer.username != null)
{
httpClient.getState().setCredentials(new AuthScope(AuthScope.ANY_HOST, AuthScope.ANY_PORT), new UsernamePasswordCredentials(remoteServer.username, remoteServer.password));
}
}
}