diff options
author | scottkurz <scottkurz@13f79535-47bb-0310-9956-ffa450edef68> | 2011-01-26 01:23:44 +0000 |
---|---|---|
committer | scottkurz <scottkurz@13f79535-47bb-0310-9956-ffa450edef68> | 2011-01-26 01:23:44 +0000 |
commit | 298bd0043eef84d28bb6559b489f765873a92f70 (patch) | |
tree | 6a4721216fbae62524f4b6411a0faf2c7f49329c /sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org | |
parent | dac345d5480d52c4071c22fbdeba605dc1236cc0 (diff) |
Commit some more multiple output tests and un-ignore existing ones.
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@1063552 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org')
5 files changed, 36 insertions, 11 deletions
diff --git a/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderService.java b/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderService.java index d738dd58fc..718be0b46d 100644 --- a/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderService.java +++ b/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderService.java @@ -46,11 +46,11 @@ public interface OrderService { public String[] reviewOrderTwoOutHolders(
@WebParam(name = "myData", targetNamespace = "", mode = WebParam.Mode.OUT)
Holder<Order> myData,
- @WebParam(name = "myOutParam", targetNamespace = "", mode = WebParam.Mode.OUT)
+ @WebParam(targetNamespace = "", mode = WebParam.Mode.OUT)
Holder<Float> myOutParam);
public String[] reviewOrderTwoInOutsThenIn(
- @WebParam(name = "myData", targetNamespace = "", mode = WebParam.Mode.INOUT)
+ @WebParam(targetNamespace = "", mode = WebParam.Mode.INOUT)
Holder<Order> myData,
@WebParam(name = "myOutParam", targetNamespace = "", mode = WebParam.Mode.INOUT)
Holder<Float> myOutParam,
@@ -62,5 +62,11 @@ public interface OrderService { @WebParam(name = "myOutParam", targetNamespace = "", mode = WebParam.Mode.INOUT)
Holder<Float> myOutParam);
+ public String[] reviewOrderOutThenInOut(
+ @WebParam(name = "myOutParam", targetNamespace = "", mode = WebParam.Mode.OUT)
+ Holder<Float> myOutParam,
+ @WebParam(name = "myData", targetNamespace = "", mode = WebParam.Mode.INOUT)
+ Holder<Order> myData);
+
}
diff --git a/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderServiceBareForwardImpl.java b/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderServiceBareForwardImpl.java index 644ee86652..7fe39da381 100644 --- a/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderServiceBareForwardImpl.java +++ b/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderServiceBareForwardImpl.java @@ -24,6 +24,6 @@ public class OrderServiceBareForwardImpl implements OrderServiceBare { @Override
public void bareReviewOrderOutHolder(Holder<Order> myData) {
- ref.bareReviewOrderInOutHolder(myData);
+ ref.bareReviewOrderOutHolder(myData);
}
}
diff --git a/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderServiceBareImpl.java b/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderServiceBareImpl.java index fbf68fab7a..05b8538c2a 100644 --- a/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderServiceBareImpl.java +++ b/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderServiceBareImpl.java @@ -46,24 +46,30 @@ public class OrderServiceBareImpl implements OrderServiceBare { @Override
public void bareReviewOrderInOutHolder(Holder<Order> myData) {
+ String customerId = "cust1234";
double total = myData.value.getTotal();
- myData.value = new Order();
+ Order newOrder = new Order();
+
if ( total < 100.0 ) {
- myData.value.setStatus( Status.APPROVED );
+ newOrder.setStatus( Status.APPROVED );
} else if ( total > 1100.0 ) {
- myData.value.setStatus( Status.REJECTED );
- }
+ newOrder.setStatus( Status.REJECTED );
+ }
+ newOrder.setCustomerId(customerId);
+ myData.value = newOrder;
}
@Override
public void bareReviewOrderOutHolder(Holder<Order> myData) {
boolean holderEmpty = (myData.value == null ? true : false);
- myData.value = new Order();
+ Order newOrder = new Order();
+
if (holderEmpty) {
- myData.value.setStatus( Status.APPROVED );
- myData.value.setCustomerId("approved.1234");
+ newOrder.setStatus( Status.APPROVED );
+ newOrder.setCustomerId("approved.1234");
} else {
- myData.value.setStatus( Status.REJECTED );
+ newOrder.setStatus( Status.REJECTED );
}
+ myData.value = newOrder;
}
}
diff --git a/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderServiceForwardImpl.java b/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderServiceForwardImpl.java index 4c89fd59a7..9628963a5e 100644 --- a/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderServiceForwardImpl.java +++ b/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderServiceForwardImpl.java @@ -42,5 +42,11 @@ public class OrderServiceForwardImpl implements OrderService { ref.reviewOrderTwoInOutsVoid(myData, myOutParam);
}
+ @Override
+ public String[] reviewOrderOutThenInOut(Holder<Float> myOutParam, Holder<Order> myData) {
+ String[] retVal = ref.reviewOrderOutThenInOut(myOutParam, myData);
+ return retVal;
+ }
+
}
diff --git a/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderServiceImpl.java b/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderServiceImpl.java index 46eb8a6307..8ec9a94248 100644 --- a/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderServiceImpl.java +++ b/sca-java-2.x/trunk/testing/itest/ws/holder-ws-service-multiple-outputs/src/main/java/org/example/orderservice/OrderServiceImpl.java @@ -155,4 +155,11 @@ public class OrderServiceImpl implements OrderService { }
myData.value = retOrder;
}
+
+ @Override
+ // Simply delegate to existing test method with parms reversed.
+ public String[] reviewOrderOutThenInOut(Holder<Float> myOutParam, Holder<Order> myData) {
+ String[] retVal = reviewOrder(myData, myOutParam);
+ return retVal;
+ }
}
|