You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jackrabbit.apache.org by md...@apache.org on 2009/10/05 15:19:31 UTC
svn commit: r821791 -
/jackrabbit/trunk/jackrabbit-jcr-client/src/test/java/org/apache/jackrabbit/client/RepositoryFactoryImplTest.java
Author: mduerig
Date: Mon Oct 5 13:19:31 2009
New Revision: 821791
URL: http://svn.apache.org/viewvc?rev=821791&view=rev
Log:
JCR-2326: some jcr-client tests fail if a server runs on localhost:80
Modified:
jackrabbit/trunk/jackrabbit-jcr-client/src/test/java/org/apache/jackrabbit/client/RepositoryFactoryImplTest.java
Modified: jackrabbit/trunk/jackrabbit-jcr-client/src/test/java/org/apache/jackrabbit/client/RepositoryFactoryImplTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-jcr-client/src/test/java/org/apache/jackrabbit/client/RepositoryFactoryImplTest.java?rev=821791&r1=821790&r2=821791&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-jcr-client/src/test/java/org/apache/jackrabbit/client/RepositoryFactoryImplTest.java (original)
+++ jackrabbit/trunk/jackrabbit-jcr-client/src/test/java/org/apache/jackrabbit/client/RepositoryFactoryImplTest.java Mon Oct 5 13:19:31 2009
@@ -150,6 +150,9 @@
Repository repo = factory.getRepository(parameters);
assertNotNull(repo);
} catch (RepositoryException e) {
+ // If there is no jcr server on localhost, one of the below
+ // exceptions will be thrown. Since this indicates that the
+ // factory is working correctly, it is safe to ignore them.
if (!(ConnectException.class.isInstance(e.getCause()) ||
DavException.class.isInstance(e.getCause()))) {
throw e;
@@ -166,6 +169,9 @@
Repository repo = factory.getRepository(parameters);
assertNotNull(repo);
} catch (RepositoryException e) {
+ // If there is no jcr server on localhost, one of the below
+ // exceptions will be thrown. Since this indicates that the
+ // factory is working correctly, it is safe to ignore them.
if (!(ConnectException.class.isInstance(e.getCause()) ||
DavException.class.isInstance(e.getCause()))) {
throw e;