diff --git a/VERSION.txt b/VERSION.txt index 69fcb44d8ec..cc1d36a346f 100644 --- a/VERSION.txt +++ b/VERSION.txt @@ -1,3 +1,4 @@ + + 331703 Fixed failing OSGI test TestJettyOSGiBootWithJsp.java on MacOSX + 331567 IPAccessHandlerTest failed on MacOS fix + 328789 Clean up tmp files from test harnesses + 331230 Fixed low thread warnings when acceptors>threadpool diff --git a/jetty-osgi/test-jetty-osgi/src/test/java/org/eclipse/jetty/osgi/boot/TestJettyOSGiBootCore.java b/jetty-osgi/test-jetty-osgi/src/test/java/org/eclipse/jetty/osgi/boot/TestJettyOSGiBootCore.java index c8e49ac861c..077d3d75fb9 100644 --- a/jetty-osgi/test-jetty-osgi/src/test/java/org/eclipse/jetty/osgi/boot/TestJettyOSGiBootCore.java +++ b/jetty-osgi/test-jetty-osgi/src/test/java/org/eclipse/jetty/osgi/boot/TestJettyOSGiBootCore.java @@ -33,12 +33,12 @@ import junit.framework.Assert; import org.eclipse.jetty.client.ContentExchange; import org.eclipse.jetty.client.HttpClient; +import org.eclipse.jetty.client.HttpExchange; import org.eclipse.jetty.http.HttpMethods; import org.eclipse.jetty.http.HttpStatus; import org.eclipse.jetty.osgi.boot.internal.serverfactory.DefaultJettyAtJettyHomeHelper; import org.junit.Test; import org.junit.runner.RunWith; -import org.ops4j.pax.exam.CoreOptions; import org.ops4j.pax.exam.Inject; import org.ops4j.pax.exam.Option; import org.ops4j.pax.exam.container.def.PaxRunnerOptions; @@ -169,11 +169,12 @@ public class TestJettyOSGiBootCore client.start(); ContentExchange getExchange = new ContentExchange(); - getExchange.setURL("http://localhost:9876/greetings"); + getExchange.setURL("http://127.0.0.1:9876/greetings"); getExchange.setMethod(HttpMethods.GET); client.send(getExchange); int state = getExchange.waitForDone(); + Assert.assertEquals("state should be done", HttpExchange.STATUS_COMPLETED, state); String content = null; int responseStatus = getExchange.getResponseStatus(); diff --git a/jetty-osgi/test-jetty-osgi/src/test/java/org/eclipse/jetty/osgi/boot/TestJettyOSGiBootWithJsp.java b/jetty-osgi/test-jetty-osgi/src/test/java/org/eclipse/jetty/osgi/boot/TestJettyOSGiBootWithJsp.java index 6c94eb2f9fb..1e9a0941c3f 100644 --- a/jetty-osgi/test-jetty-osgi/src/test/java/org/eclipse/jetty/osgi/boot/TestJettyOSGiBootWithJsp.java +++ b/jetty-osgi/test-jetty-osgi/src/test/java/org/eclipse/jetty/osgi/boot/TestJettyOSGiBootWithJsp.java @@ -27,6 +27,7 @@ import junit.framework.Assert; import org.eclipse.jetty.client.ContentExchange; import org.eclipse.jetty.client.HttpClient; +import org.eclipse.jetty.client.HttpExchange; import org.eclipse.jetty.http.HttpMethods; import org.eclipse.jetty.http.HttpStatus; import org.junit.Test; @@ -118,12 +119,13 @@ public class TestJettyOSGiBootWithJsp client.start(); ContentExchange getExchange = new ContentExchange(); - getExchange.setURL("http://localhost:9876/jsp/dump.jsp"); + getExchange.setURL("http://127.0.0.1:9876/jsp/dump.jsp"); getExchange.setMethod(HttpMethods.GET); client.send(getExchange); int state = getExchange.waitForDone(); - + Assert.assertEquals("state should be done", HttpExchange.STATUS_COMPLETED, state); + String content = null; int responseStatus = getExchange.getResponseStatus(); Assert.assertEquals(HttpStatus.OK_200, responseStatus);