cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cschnei...@apache.org
Subject svn commit: r1497660 - /cxf/dosgi/trunk/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/AbstractDosgiTest.java
Date Fri, 28 Jun 2013 07:04:12 GMT
Author: cschneider
Date: Fri Jun 28 07:04:12 2013
New Revision: 1497660

URL: http://svn.apache.org/r1497660
Log:
Correctly handle ConnectException

Modified:
    cxf/dosgi/trunk/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/AbstractDosgiTest.java

Modified: cxf/dosgi/trunk/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/AbstractDosgiTest.java
URL: http://svn.apache.org/viewvc/cxf/dosgi/trunk/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/AbstractDosgiTest.java?rev=1497660&r1=1497659&r2=1497660&view=diff
==============================================================================
--- cxf/dosgi/trunk/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/AbstractDosgiTest.java
(original)
+++ cxf/dosgi/trunk/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/AbstractDosgiTest.java
Fri Jun 28 07:04:12 2013
@@ -19,6 +19,7 @@
 package org.apache.cxf.dosgi.systests2.multi;
 
 import java.io.IOException;
+import java.net.ConnectException;
 import java.net.HttpURLConnection;
 import java.net.MalformedURLException;
 import java.net.ServerSocket;
@@ -110,11 +111,14 @@ public class AbstractDosgiTest {
     protected void waitWebPage(String urlSt) throws InterruptedException {
         int status = 0;
         int seconds = 0;
+        System.out.println("Waiting for url " + urlSt);
         while (status != 200) {
             try {
                 URL url = new URL(urlSt);
                 HttpURLConnection con = (HttpURLConnection)url.openConnection();
                 status = con.getResponseCode();
+            } catch (ConnectException e) {
+                // Ignore connection refused
             } catch (MalformedURLException e) {
                 throw new RuntimeException(e.getMessage(), e);
             } catch (IOException e) {



Mime
View raw message