You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-commits@axis.apache.org by ve...@apache.org on 2015/06/20 17:50:46 UTC
svn commit: r1686643 -
/axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/rest/RESTfulServiceTest.java
Author: veithen
Date: Sat Jun 20 15:50:46 2015
New Revision: 1686643
URL: http://svn.apache.org/r1686643
Log:
Fix a broken test case introduced by AXIS2-5247. To the author of that test, please repeat 100 times: "A unit test must not depend the side effects of another unit test."
Note that the issue occurs only on Java 7. With this patch, AXIS2-5307 should be completely fixed.
Modified:
axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/rest/RESTfulServiceTest.java
Modified: axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/rest/RESTfulServiceTest.java
URL: http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/rest/RESTfulServiceTest.java?rev=1686643&r1=1686642&r2=1686643&view=diff
==============================================================================
--- axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/rest/RESTfulServiceTest.java (original)
+++ axis/axis2/java/core/trunk/modules/integration/test/org/apache/axis2/rest/RESTfulServiceTest.java Sat Jun 20 15:50:46 2015
@@ -23,7 +23,6 @@ import junit.framework.Test;
import junit.framework.TestSuite;
import org.apache.axiom.om.OMElement;
import org.apache.axiom.om.util.AXIOMUtil;
-import org.apache.axis2.AxisFault;
import org.apache.axis2.Constants;
import org.apache.axis2.context.ConfigurationContext;
import org.apache.axis2.context.ConfigurationContextFactory;
@@ -59,7 +58,7 @@ public class RESTfulServiceTest extends
createConfigurationContextFromFileSystem(null, null);
}
- public void testServiceCreate() throws AxisFault {
+ public void test() throws Exception {
AxisConfiguration axisConfig = configContext.getAxisConfiguration();
AxisService axisService =
AxisService.createService("org.apache.axis2.rest.StockService", axisConfig);
@@ -133,10 +132,6 @@ public class RESTfulServiceTest extends
axisConfig.addService(axisService);
assertEquals("StockService", axisService.getName());
- }
-
- public void testRESTMethods() throws Exception {
-
HttpClient httpClient = new HttpClient();
String url1 = "http://127.0.0.1:" + (UtilServer.TESTING_PORT)