You are viewing a plain text version of this content. The canonical link for it is here.
Posted to axis-cvs@ws.apache.org by di...@apache.org on 2007/06/26 04:37:21 UTC
svn commit: r550661 -
/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMCommonsChunkingTest.java
Author: dims
Date: Mon Jun 25 19:37:20 2007
New Revision: 550661
URL: http://svn.apache.org/viewvc?view=rev&rev=550661
Log:
Fix bad test - actually get the return element and check if it is the same as the one sent!
Modified:
webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMCommonsChunkingTest.java
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMCommonsChunkingTest.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMCommonsChunkingTest.java?view=diff&rev=550661&r1=550660&r2=550661
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMCommonsChunkingTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMCommonsChunkingTest.java Mon Jun 25 19:37:20 2007
@@ -41,7 +41,6 @@
import javax.activation.DataHandler;
import javax.activation.FileDataSource;
-import java.net.URL;
public class EchoRawMTOMCommonsChunkingTest extends UtilServerBasedTestCase
implements TestConstants {
@@ -108,21 +107,17 @@
sender.setOptions(options);
options.setTo(targetEPR);
- sender.sendReceive(payload);
- this.campareWithCreatedOMElement(data);
+ OMElement ret = sender.sendReceive(payload);
+ ret.build();
+ this.compareWithCreatedOMElement(ret);
}
- private URL getResourceAsStream(String path) {
- ClassLoader cl = Thread.currentThread().getContextClassLoader();
- return cl.getResource(path);
- }
-
- private void campareWithCreatedOMElement(OMElement element) {
+ private void compareWithCreatedOMElement(OMElement element) {
OMElement firstChild = element.getFirstElement();
TestCase.assertNotNull(firstChild);
String originalTextValue = data.getFirstElement().getText();
- String returnedTextValue = firstChild.getText();
+ String returnedTextValue = firstChild.getFirstElement().getText();
TestCase.assertEquals(returnedTextValue, originalTextValue);
}
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org