Author: keith
Date: Mon Mar 31 04:49:05 2008
New Revision: 15399
Log:
Fixing some testcases to cope with xsi:type change
Modified:
trunk/mashup/java/modules/integration/test/org/wso2/mashup/integration/SchemaIntegrationTest.java
Modified:
trunk/mashup/java/modules/integration/test/org/wso2/mashup/integration/SchemaIntegrationTest.java
==============================================================================
---
trunk/mashup/java/modules/integration/test/org/wso2/mashup/integration/SchemaIntegrationTest.java
(original)
+++
trunk/mashup/java/modules/integration/test/org/wso2/mashup/integration/SchemaIntegrationTest.java
Mon Mar 31 04:49:05 2008
@@ -108,10 +108,10 @@
OMElement result = sender.sendReceive(payload);
OMElement element = result.getFirstElement();
TestCase.assertEquals(
- "<return xmlns:js=\"http://www.wso2.org/ns/jstype\"
js:type=\"array\">" +
- "<item js:type=\"string\">testParam</item>" +
- "<item js:type=\"string\">testParam</item>" +
- "<item js:type=\"string\">testParam</item>" +
+ "<return xmlns:xs=\"http://www.w3.org/2001/XMLSchema\"
xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"
xmlns:js=\"http://www.wso2.org/ns/jstype\" js:type=\"array\">" +
+ "<item js:type=\"string\"
xsi:type=\"xs:string\">testParam</item>" +
+ "<item js:type=\"string\"
xsi:type=\"xs:string\">testParam</item>" +
+ "<item js:type=\"string\"
xsi:type=\"xs:string\">testParam</item>" +
"</return>",
element.toString());
}
@@ -127,7 +127,7 @@
OMElement result = sender.sendReceive(payload);
OMElement element = result.getFirstElement();
TestCase.assertEquals(
- "<return xmlns:js=\"http://www.wso2.org/ns/jstype\"
js:type=\"array\">" +
+ "<return xmlns:xs=\"http://www.w3.org/2001/XMLSchema\"
xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"
xmlns:js=\"http://www.wso2.org/ns/jstype\" js:type=\"array\">" +
"<item js:type=\"string\">value1</item>" +
"<item js:type=\"number\">2.27</item>" +
"<item js:type=\"xml\"><value>2</value></item>" +
@@ -146,10 +146,10 @@
OMElement result = sender.sendReceive(payload);
OMElement element = result.getFirstElement();
TestCase.assertEquals(
- "<return xmlns:js=\"http://www.wso2.org/ns/jstype\"
js:type=\"array\">" +
- "<value1 js:type=\"string\">value1</value1>" +
- "<value2 js:type=\"number\">2.27</value2>" +
- "<value3 js:type=\"xml\"><value>2</value></value3>" +
+ "<return xmlns:xs=\"http://www.w3.org/2001/XMLSchema\"
xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"
xmlns:js=\"http://www.wso2.org/ns/jstype\" js:type=\"array\">" +
+ "<value1 js:type=\"string\"
xsi:type=\"xs:string\">value1</value1>" +
+ "<value2 js:type=\"number\"
xsi:type=\"xs:double\">2.27</value2>" +
+ "<value3 js:type=\"xml\"
xsi:type=\"xs:anyType\"><value>2</value></value3>" +
"</return>",
element.toString());
}
@@ -170,10 +170,10 @@
OMElement result = sender.sendReceive(payload);
OMElement element = result.getFirstElement();
TestCase.assertEquals(
- "<return xmlns:js=\"http://www.wso2.org/ns/jstype\"
js:type=\"object\">" +
- "<param1 js:type=\"string\">testParam</param1>" +
- "<param2 js:type=\"number\">10.0</param2>" +
- "<param3 js:type=\"boolean\">true</param3>" +
+ "<return xmlns:xs=\"http://www.w3.org/2001/XMLSchema\"
xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"
xmlns:js=\"http://www.wso2.org/ns/jstype\" js:type=\"object\">" +
+ "<param1 js:type=\"string\"
xsi:type=\"xs:string\">testParam</param1>" +
+ "<param2 js:type=\"number\"
xsi:type=\"xs:double\">10.0</param2>" +
+ "<param3 js:type=\"boolean\"
xsi:type=\"xs:boolean\">true</param3>" +
"</return>",
element.toString());
}
@@ -421,8 +421,8 @@
sender.setOptions(options);
OMElement result = sender.sendReceive(payload);
TestCase.assertEquals(
- "<return xmlns:js=\"http://www.wso2.org/ns/jstype\"
js:type=\"number\">" +
- "10.0</return>",
+ "<return xmlns:xs=\"http://www.w3.org/2001/XMLSchema\"
xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"
xmlns:js=\"http://www.wso2.org/ns/jstype\" " +
+ "js:type=\"number\"
xsi:type=\"xs:double\">10.0</return>",
result.getFirstElement().toString());
}
@@ -438,8 +438,8 @@
sender.setOptions(options);
OMElement result = sender.sendReceive(payload);
TestCase.assertEquals(
- "<return xmlns:js=\"http://www.wso2.org/ns/jstype\"
js:type=\"boolean\">" +
- "true</return>",
+ "<return xmlns:xs=\"http://www.w3.org/2001/XMLSchema\"
xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"
xmlns:js=\"http://www.wso2.org/ns/jstype\" " +
+ "js:type=\"boolean\"
xsi:type=\"xs:boolean\">true</return>",
result.getFirstElement().toString());
}
@@ -589,14 +589,14 @@
"<ws:echoComplexCompositionsResponseTypecomplex1Type>"
+
"<nested2>true</nested2>" +
"<nested2>true</nested2>" +
- "<nested3 xmlns:js=\"http://www.wso2.org/ns/jstype\"
js:type=\"array\">" +
- "<item js:type=\"xml\"><test>just some
text</test></item>" +
+ "<nested3
xmlns:xs=\"http://www.w3.org/2001/XMLSchema\"
xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"
xmlns:js=\"http://www.wso2.org/ns/jstype\" js:type=\"array\">" +
+ "<item js:type=\"xml\"
xsi:type=\"xs:anyType\"><test>just some text</test></item>" +
"</nested3>" +
"<nested1>10.0</nested1>" +
"</ws:echoComplexCompositionsResponseTypecomplex1Type>" +
"<ws:echoComplexCompositionsResponseTypecomplex2Type>"
+
"<anotherNested
xmlns:js=\"http://www.wso2.org/ns/jstype\" js:type=\"array\">" +
- "<item js:type=\"xml\"><test>just some
text</test></item>" +
+ "<item js:type=\"xml\"
xsi:type=\"xs:anyType\"><test>just some text</test></item>" +
"</anotherNested>" +
"</ws:echoComplexCompositionsResponseTypecomplex2Type>" +
"<simple3>2007-08-27T10:20:30.040+00:00</simple3>" +
@@ -741,7 +741,7 @@
sender.setOptions(options);
OMElement result = sender.sendReceive(payload);
TestCase.assertEquals(
- "<return xmlns:js=\"http://www.wso2.org/ns/jstype\"
js:type=\"xmlList\"><successful /><excess /></return>",
+ "<return xmlns:xs=\"http://www.w3.org/2001/XMLSchema\"
xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"
xmlns:js=\"http://www.wso2.org/ns/jstype\" js:type=\"xmlList\"
xsi:type=\"xs:anyType\"><successful /><excess /></return>",
result.getFirstElement().getFirstElement().toString());
}
_______________________________________________
Mashup-dev mailing list
[email protected]
http://www.wso2.org/cgi-bin/mailman/listinfo/mashup-dev