You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@beehive.apache.org by ek...@apache.org on 2005/06/14 21:36:41 UTC

svn commit: r190652 [2/7] - in /incubator/beehive/trunk/wsm: drt/negative/WEB-INF/ drt/negative/WEB-INF/src/ drt/negative/WEB-INF/src/web/negative/ drt/tests/org/apache/beehive/wsm/jsr181/model/ drt/tests/org/apache/beehive/wsm/jsr181/model/fakeAnnotations/ drt/tests/org/apache/beehive/wsm/jsr181/processor/apt/ drt/tests/org/apache/beehive/wsm/jsr181/wsdl/ drt/webapp/WEB-INF/ drt/webapp/WEB-INF/src/ drt/webapp/WEB-INF/src/org/apache/beehive/wsm/axis/ drt/webapp/WEB-INF/src/web/ schemas/ src/api/javax/jws/ src/api/javax/jws/soap/ src/runtime/META-INF/services/ src/runtime/org/apache/beehive/wsm/axis/ src/runtime/org/apache/beehive/wsm/axis/ant/ src/runtime/org/apache/beehive/wsm/axis/databinding/ src/runtime/org/apache/beehive/wsm/axis/handlers/ src/runtime/org/apache/beehive/wsm/axis/registration/ src/runtime/org/apache/beehive/wsm/axis/tools/ src/runtime/org/apache/beehive/wsm/axis/util/ src/runtime/org/apache/beehive/wsm/databinding/ src/runtime/org/apache/beehive/wsm/databinding/xmlbeans/ src/runtime/org/apache/beehive/wsm/model/ src/runtime/org/apache/beehive/wsm/model/java/ src/runtime/org/apache/beehive/wsm/model/jsr181/ src/runtime/org/apache/beehive/wsm/processor/apt/ src/runtime/org/apache/beehive/wsm/registration/ src/runtime/org/apache/beehive/wsm/util/ src/runtime/org/apache/beehive/wsm/wsdl/

Modified: incubator/beehive/trunk/wsm/drt/tests/org/apache/beehive/wsm/jsr181/model/BarTestCase.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/tests/org/apache/beehive/wsm/jsr181/model/BarTestCase.java?rev=190652&r1=190651&r2=190652&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/drt/tests/org/apache/beehive/wsm/jsr181/model/BarTestCase.java (original)
+++ incubator/beehive/trunk/wsm/drt/tests/org/apache/beehive/wsm/jsr181/model/BarTestCase.java Tue Jun 14 12:36:38 2005
@@ -1,159 +1,159 @@
-/*
- * Copyright 2004 The Apache Software Foundation
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- * $Header:$
- */
-package org.apache.beehive.wsm.jsr181.model;
-
-import java.util.Collection;
-
-import junit.framework.TestCase;
-import org.apache.beehive.wsm.model.BeehiveWsTypeMetadata;
-import org.apache.beehive.wsm.model.BeehiveWsMethodMetadata;
-import org.apache.beehive.wsm.model.BeehiveWsParameterMetadata;
-
-/**
- * This class serves as the base class for all TestCases based on Bar.java. It
- * verifies the values of all parameters in the object model defined in Cheetorama.java
- * specified as the @WebService.endpointInterface annotation in Bar.java.
- * Default values are expected to be filled in. If a subclass can't fully comply
- * with JSR-181 (e.g. if it can't fill in all default values) it needs to
- * override the respective tests.
- */
-public class BarTestCase extends TestCase {
-    protected static final String CLASSNAME = "web.Bar";
-    protected static final String[] SRCFILENAMES = {"web/Bar.jws"};
-
-    protected BeehiveWsTypeMetadata objectModel;
-
-    public void testObjectModel() throws Exception {
-        assertNotNull("Failed to retrieve object model;", objectModel);
-    }
-
-    public void testWebServiceAbacus() throws Exception {
-        assertEquals("Invalid wsName;", "Abacus",
-                ((BeehiveWsTypeMetadata) objectModel).getWsName());
-        assertEquals("Invalid wsTargetNamespace;",
-                "http://www.superflaco.com/AnnotationEndpointInterfaceTest",
-                ((BeehiveWsTypeMetadata) objectModel).getWsTargetNamespace());
-    }
-
-    public void testWebMethodGoLoco() throws Exception {
-        BeehiveWsMethodMetadata method = getMethod("GoLoco");
-        assertNull("WebMethod GoLoco() must be null", method);
-        method = getMethod("GoLocoCheetorama");
-        assertNotNull("Cannot find WebMethod GoLocoCheetorama();", method);
-        assertEquals("Invalid wmAction;", "LocoActionCheetorama", method.getWmAction());
-        assertFalse("Unexpected @Oneway;", method.isOneWay());
-        assertEquals("Invalid wrName;", "return", method.getWrName());
-        assertEquals("Invalid return type;",
-                boolean.class,
-                method.getJavaReturnType());
-    }
-
-    public void testWebMethodGoHome() throws Exception {
-        BeehiveWsMethodMetadata method = getMethod("goHome");
-        assertNotNull("Cannot find WebMethod goHome();", method);
-        assertEquals("Invalid wmAction;", "", method.getWmAction());
-        assertTrue("Cannot find @Oneway;", method.isOneWay());
-        assertEquals("Unexpected @WebResult;", "return", method.getWrName());
-        assertEquals("Unexpected return type;",
-                void.class,
-                method.getJavaReturnType());
-    }
-
-    public void testWebMethodDropMoney() throws Exception {
-        BeehiveWsMethodMetadata method = getMethod("dropMoney");
-        assertNotNull("Cannot find WebMethod dropMoney();", method);
-        assertEquals("Invalid wmAction;", "", method.getWmAction());
-        assertFalse("Unexpected @Oneway;", method.isOneWay());
-        assertEquals("Unexpected @WebResult;", "return", method.getWrName());
-        assertEquals("Unexpected return type;",
-                int.class,
-                method.getJavaReturnType());
-    }
-
-    public void testWebParamGoLocoFirst() throws Exception {
-        final int paramNo = 0;
-        BeehiveWsParameterMetadata param = getParam("GoLocoCheetorama", paramNo);
-        assertNotNull("Cannot find first param for WebMethod GoLoco();", param);
-        assertEquals("Invalid wpName;", "level", param.getWpName());
-        assertEquals("Invalid return type: " + param.getJavaType(),
-                int.class,
-                param.getJavaType());
-    }
-
-    public void testWebParamGoLocoSecond() throws Exception {
-        final int paramNo = 1;
-        BeehiveWsParameterMetadata param = getParam("GoLocoCheetorama", paramNo);
-        assertNotNull("Cannot find second param for WebMethod GoLoco();", param);
-        assertEquals("Invalid wpName;", "detailCheetorama", param.getWpName());
-        assertEquals("Invalid return type: " + param.getJavaType(),
-                String.class,
-                param.getJavaType());
-    }
-
-    public void testWebParamGoHomeFirst() throws Exception {
-        final int paramNo = 0;
-        BeehiveWsParameterMetadata param = getParam("goHome", paramNo);
-        assertNotNull("Cannot find first param for method goHome();", param);
-        assertEquals("Invalid wpName;", "whenCheetorama", param.getWpName());
-        assertEquals("Invalid return type: " + param.getJavaType(),
-                long.class,
-                param.getJavaType());
-    }
-
-    public void testWebParamDropMoneyFirst() throws Exception {
-        final int paramNo = 0;
-        BeehiveWsParameterMetadata param = getParam("dropMoney", paramNo);
-        assertNotNull("Cannot find first param for method dropMoney();", param);
-        assertEquals("Invalid wpName;", "amount", param.getWpName());
-        assertEquals("Invalid return type: " + param.getJavaType(),
-                int.class,
-                param.getJavaType());
-    }
-
-    protected BeehiveWsMethodMetadata getMethod(String methodName) {
-        if ((null == methodName) || (null == objectModel)) {
-            return null;
-        }
-        for (BeehiveWsMethodMetadata method : ((BeehiveWsTypeMetadata) objectModel).getMethods()) {
-            if (methodName.equals(method.getWmOperationName())) {
-                return method;
-            }
-        }
-        return null;
-    }
-
-    protected BeehiveWsParameterMetadata getParam(String methodName, int pos) {
-        if ((null == methodName) || (null == objectModel)) {
-            return null;
-        }
-        Collection<? extends BeehiveWsMethodMetadata> webMethods =
-                ((BeehiveWsTypeMetadata) objectModel).getMethods();
-        for (BeehiveWsMethodMetadata method : webMethods) {
-            if (methodName.equals(method.getWmOperationName())) {
-                int i = 0;
-                for (BeehiveWsParameterMetadata param : method.getParams()) {
-                    if (i == pos) {
-                        return param;
-                    }
-                    i++;
-                }
-            }
-        }
-        return null;
-    }
-}
+/*
+ * Copyright 2004 The Apache Software Foundation
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ * $Header:$
+ */
+package org.apache.beehive.wsm.jsr181.model;
+
+import java.util.Collection;
+
+import junit.framework.TestCase;
+import org.apache.beehive.wsm.model.BeehiveWsTypeMetadata;
+import org.apache.beehive.wsm.model.BeehiveWsMethodMetadata;
+import org.apache.beehive.wsm.model.BeehiveWsParameterMetadata;
+
+/**
+ * This class serves as the base class for all TestCases based on Bar.java. It
+ * verifies the values of all parameters in the object model defined in Cheetorama.java
+ * specified as the @WebService.endpointInterface annotation in Bar.java.
+ * Default values are expected to be filled in. If a subclass can't fully comply
+ * with JSR-181 (e.g. if it can't fill in all default values) it needs to
+ * override the respective tests.
+ */
+public class BarTestCase extends TestCase {
+    protected static final String CLASSNAME = "web.Bar";
+    protected static final String[] SRCFILENAMES = {"web/Bar.jws"};
+
+    protected BeehiveWsTypeMetadata objectModel;
+
+    public void testObjectModel() throws Exception {
+        assertNotNull("Failed to retrieve object model;", objectModel);
+    }
+
+    public void testWebServiceAbacus() throws Exception {
+        assertEquals("Invalid wsName;", "Abacus",
+                ((BeehiveWsTypeMetadata) objectModel).getWsName());
+        assertEquals("Invalid wsTargetNamespace;",
+                "http://www.superflaco.com/AnnotationEndpointInterfaceTest",
+                ((BeehiveWsTypeMetadata) objectModel).getWsTargetNamespace());
+    }
+
+    public void testWebMethodGoLoco() throws Exception {
+        BeehiveWsMethodMetadata method = getMethod("GoLoco");
+        assertNull("WebMethod GoLoco() must be null", method);
+        method = getMethod("GoLocoCheetorama");
+        assertNotNull("Cannot find WebMethod GoLocoCheetorama();", method);
+        assertEquals("Invalid wmAction;", "LocoActionCheetorama", method.getWmAction());
+        assertFalse("Unexpected @Oneway;", method.isOneWay());
+        assertEquals("Invalid wrName;", "return", method.getWrName());
+        assertEquals("Invalid return type;",
+                boolean.class,
+                method.getJavaReturnType());
+    }
+
+    public void testWebMethodGoHome() throws Exception {
+        BeehiveWsMethodMetadata method = getMethod("goHome");
+        assertNotNull("Cannot find WebMethod goHome();", method);
+        assertEquals("Invalid wmAction;", "", method.getWmAction());
+        assertTrue("Cannot find @Oneway;", method.isOneWay());
+        assertEquals("Unexpected @WebResult;", "return", method.getWrName());
+        assertEquals("Unexpected return type;",
+                void.class,
+                method.getJavaReturnType());
+    }
+
+    public void testWebMethodDropMoney() throws Exception {
+        BeehiveWsMethodMetadata method = getMethod("dropMoney");
+        assertNotNull("Cannot find WebMethod dropMoney();", method);
+        assertEquals("Invalid wmAction;", "", method.getWmAction());
+        assertFalse("Unexpected @Oneway;", method.isOneWay());
+        assertEquals("Unexpected @WebResult;", "return", method.getWrName());
+        assertEquals("Unexpected return type;",
+                int.class,
+                method.getJavaReturnType());
+    }
+
+    public void testWebParamGoLocoFirst() throws Exception {
+        final int paramNo = 0;
+        BeehiveWsParameterMetadata param = getParam("GoLocoCheetorama", paramNo);
+        assertNotNull("Cannot find first param for WebMethod GoLoco();", param);
+        assertEquals("Invalid wpName;", "level", param.getWpName());
+        assertEquals("Invalid return type: " + param.getJavaType(),
+                int.class,
+                param.getJavaType());
+    }
+
+    public void testWebParamGoLocoSecond() throws Exception {
+        final int paramNo = 1;
+        BeehiveWsParameterMetadata param = getParam("GoLocoCheetorama", paramNo);
+        assertNotNull("Cannot find second param for WebMethod GoLoco();", param);
+        assertEquals("Invalid wpName;", "detailCheetorama", param.getWpName());
+        assertEquals("Invalid return type: " + param.getJavaType(),
+                String.class,
+                param.getJavaType());
+    }
+
+    public void testWebParamGoHomeFirst() throws Exception {
+        final int paramNo = 0;
+        BeehiveWsParameterMetadata param = getParam("goHome", paramNo);
+        assertNotNull("Cannot find first param for method goHome();", param);
+        assertEquals("Invalid wpName;", "whenCheetorama", param.getWpName());
+        assertEquals("Invalid return type: " + param.getJavaType(),
+                long.class,
+                param.getJavaType());
+    }
+
+    public void testWebParamDropMoneyFirst() throws Exception {
+        final int paramNo = 0;
+        BeehiveWsParameterMetadata param = getParam("dropMoney", paramNo);
+        assertNotNull("Cannot find first param for method dropMoney();", param);
+        assertEquals("Invalid wpName;", "amount", param.getWpName());
+        assertEquals("Invalid return type: " + param.getJavaType(),
+                int.class,
+                param.getJavaType());
+    }
+
+    protected BeehiveWsMethodMetadata getMethod(String methodName) {
+        if ((null == methodName) || (null == objectModel)) {
+            return null;
+        }
+        for (BeehiveWsMethodMetadata method : ((BeehiveWsTypeMetadata) objectModel).getMethods()) {
+            if (methodName.equals(method.getWmOperationName())) {
+                return method;
+            }
+        }
+        return null;
+    }
+
+    protected BeehiveWsParameterMetadata getParam(String methodName, int pos) {
+        if ((null == methodName) || (null == objectModel)) {
+            return null;
+        }
+        Collection<? extends BeehiveWsMethodMetadata> webMethods =
+                ((BeehiveWsTypeMetadata) objectModel).getMethods();
+        for (BeehiveWsMethodMetadata method : webMethods) {
+            if (methodName.equals(method.getWmOperationName())) {
+                int i = 0;
+                for (BeehiveWsParameterMetadata param : method.getParams()) {
+                    if (i == pos) {
+                        return param;
+                    }
+                    i++;
+                }
+            }
+        }
+        return null;
+    }
+}

Propchange: incubator/beehive/trunk/wsm/drt/tests/org/apache/beehive/wsm/jsr181/model/BarTestCase.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: incubator/beehive/trunk/wsm/drt/tests/org/apache/beehive/wsm/jsr181/model/FooTestCase.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/wsm/drt/tests/org/apache/beehive/wsm/jsr181/model/FooTestCase.java?rev=190652&r1=190651&r2=190652&view=diff
==============================================================================
--- incubator/beehive/trunk/wsm/drt/tests/org/apache/beehive/wsm/jsr181/model/FooTestCase.java (original)
+++ incubator/beehive/trunk/wsm/drt/tests/org/apache/beehive/wsm/jsr181/model/FooTestCase.java Tue Jun 14 12:36:38 2005
@@ -1,129 +1,129 @@
-package org.apache.beehive.wsm.jsr181.model;
-
-/*
- * Copyright 2004 The Apache Software Foundation
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- * 
- *     http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- *
- * $Header:$
- */
-
-import junit.framework.TestCase;
-import org.apache.beehive.wsm.model.BeehiveWsTypeMetadata;
-import org.apache.beehive.wsm.model.BeehiveWsMethodMetadata;
-import org.apache.beehive.wsm.model.BeehiveWsParameterMetadata;
-
-/**
- * This class serves as the base class for all TestCases based on Foo.java. It
- * verifies the values of all parameters in the object model defined in Foo.java.
- * Default values are expected to be filled in. If a subclass can't fully comply
- * with JSR-181 (e.g. if it can't fill in all default values) it needs to
- * override the respective tests.
- */
-public class FooTestCase extends TestCase {
-    protected static final String CLASSNAME = "web.Foo";
-    protected static final String SRCFILENAME = "web/Foo.jws";
-
-    protected BeehiveWsTypeMetadata objectModel;
-
-    public void testObjectModel() throws Exception {
-        assertNotNull("Failed to retrieve object model;", objectModel);
-    }
-
-    public void testWebServiceAbacus() throws Exception {
-        assertEquals("Invalid wsName;", "Abacus",
-                ((BeehiveWsTypeMetadata) objectModel).getWsName());
-        
-        // todo test endpointInterface
-
-        assertEquals("Invalid wsTargetNamespace;",
-                "http://www.superflaco.com/AnnotationTest",
-                ((BeehiveWsTypeMetadata) objectModel).getWsTargetNamespace());
-    }
-
-    public void testWebMethodGoLoco() throws Exception {
-        BeehiveWsMethodMetadata method = getMethod("GoLoco");
-        assertNotNull("Cannot find WebMethod GoLoco();", method);
-        assertEquals("Invalid wmAction;", "LocoAction", method.getWmAction());
-        assertFalse("Unexpected @Oneway;", method.isOneWay());
-        assertEquals("Invalid wrName;", "return", method.getWrName());
-        assertEquals("Invalid return type;",
-                boolean.class,
-                method.getJavaReturnType());
-    }
-
-    public void testWebMethodGoHome() throws Exception {
-        BeehiveWsMethodMetadata method = getMethod("goHome");
-        assertNotNull("Cannot find WebMethod goHome();", method);
-        assertEquals("Invalid wmAction;", "", method.getWmAction());
-        assertTrue("Cannot find @Oneway;", method.isOneWay());
-        assertEquals("Unexpected @WebResult;", "return", method.getWrName());
-        assertEquals("Unexpected return type;",
-                void.class,
-                method.getJavaReturnType());
-    }
-
-    public void testWebParamGoLocoFirst() throws Exception {
-        final int paramNo = 0;
-        BeehiveWsParameterMetadata param = getParam("GoLoco", paramNo);
-        assertNotNull("Cannot find first param for WebMethod GoLoco();", param);
-        assertEquals("Invalid wpName;", "level", param.getWpName());
-        assertEquals("Invalid return type: " + param.getJavaType(),
-                int.class,
-                param.getJavaType());
-    }
-
-    public void testWebParamGoLocoSecond() throws Exception {
-        final int paramNo = 1;
-        BeehiveWsParameterMetadata param = getParam("GoLoco", paramNo);
-        assertNotNull("Cannot find second param for WebMethod GoLoco();", param);
-        assertEquals("Invalid wpName;", "detail", param.getWpName());
-        assertEquals("Invalid return type: " + param.getJavaType(),
-                String.class,
-                param.getJavaType());
-    }
-
-    public void testWebParamGoHomeFirst() throws Exception {
-        final int paramNo = 0;
-        BeehiveWsParameterMetadata param = getParam("goHome", paramNo);
-        assertNotNull("Cannot find first param for method goHome();", param);
-        assertEquals("Invalid wpName;", "when", param.getWpName());
-        assertEquals("Invalid return type: " + param.getJavaType(),
-                long.class,
-                param.getJavaType());
-    }
-
-    protected BeehiveWsMethodMetadata getMethod(String methodName) {
-        for (BeehiveWsMethodMetadata method : ((BeehiveWsTypeMetadata) objectModel).getMethods()) {
-            if (method.getWmOperationName().equals(methodName)) {
-                return method;
-            }
-        }
-        return null;
-    }
-
-    protected BeehiveWsParameterMetadata getParam(String methodName, int pos) {
-        for (BeehiveWsMethodMetadata method : ((BeehiveWsTypeMetadata) objectModel).getMethods()) {
-            if (method.getWmOperationName().equals(methodName)) {
-                int i = 0;
-                for (BeehiveWsParameterMetadata param : method.getParams()) {
-                    if (i == pos) {
-                        return param;
-                    }
-                    i++;
-                }
-            }
-        }
-        return null;
-    }
-}
+package org.apache.beehive.wsm.jsr181.model;
+
+/*
+ * Copyright 2004 The Apache Software Foundation
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * 
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ * $Header:$
+ */
+
+import junit.framework.TestCase;
+import org.apache.beehive.wsm.model.BeehiveWsTypeMetadata;
+import org.apache.beehive.wsm.model.BeehiveWsMethodMetadata;
+import org.apache.beehive.wsm.model.BeehiveWsParameterMetadata;
+
+/**
+ * This class serves as the base class for all TestCases based on Foo.java. It
+ * verifies the values of all parameters in the object model defined in Foo.java.
+ * Default values are expected to be filled in. If a subclass can't fully comply
+ * with JSR-181 (e.g. if it can't fill in all default values) it needs to
+ * override the respective tests.
+ */
+public class FooTestCase extends TestCase {
+    protected static final String CLASSNAME = "web.Foo";
+    protected static final String SRCFILENAME = "web/Foo.jws";
+
+    protected BeehiveWsTypeMetadata objectModel;
+
+    public void testObjectModel() throws Exception {
+        assertNotNull("Failed to retrieve object model;", objectModel);
+    }
+
+    public void testWebServiceAbacus() throws Exception {
+        assertEquals("Invalid wsName;", "Abacus",
+                ((BeehiveWsTypeMetadata) objectModel).getWsName());
+        
+        // todo test endpointInterface
+
+        assertEquals("Invalid wsTargetNamespace;",
+                "http://www.superflaco.com/AnnotationTest",
+                ((BeehiveWsTypeMetadata) objectModel).getWsTargetNamespace());
+    }
+
+    public void testWebMethodGoLoco() throws Exception {
+        BeehiveWsMethodMetadata method = getMethod("GoLoco");
+        assertNotNull("Cannot find WebMethod GoLoco();", method);
+        assertEquals("Invalid wmAction;", "LocoAction", method.getWmAction());
+        assertFalse("Unexpected @Oneway;", method.isOneWay());
+        assertEquals("Invalid wrName;", "return", method.getWrName());
+        assertEquals("Invalid return type;",
+                boolean.class,
+                method.getJavaReturnType());
+    }
+
+    public void testWebMethodGoHome() throws Exception {
+        BeehiveWsMethodMetadata method = getMethod("goHome");
+        assertNotNull("Cannot find WebMethod goHome();", method);
+        assertEquals("Invalid wmAction;", "", method.getWmAction());
+        assertTrue("Cannot find @Oneway;", method.isOneWay());
+        assertEquals("Unexpected @WebResult;", "return", method.getWrName());
+        assertEquals("Unexpected return type;",
+                void.class,
+                method.getJavaReturnType());
+    }
+
+    public void testWebParamGoLocoFirst() throws Exception {
+        final int paramNo = 0;
+        BeehiveWsParameterMetadata param = getParam("GoLoco", paramNo);
+        assertNotNull("Cannot find first param for WebMethod GoLoco();", param);
+        assertEquals("Invalid wpName;", "level", param.getWpName());
+        assertEquals("Invalid return type: " + param.getJavaType(),
+                int.class,
+                param.getJavaType());
+    }
+
+    public void testWebParamGoLocoSecond() throws Exception {
+        final int paramNo = 1;
+        BeehiveWsParameterMetadata param = getParam("GoLoco", paramNo);
+        assertNotNull("Cannot find second param for WebMethod GoLoco();", param);
+        assertEquals("Invalid wpName;", "detail", param.getWpName());
+        assertEquals("Invalid return type: " + param.getJavaType(),
+                String.class,
+                param.getJavaType());
+    }
+
+    public void testWebParamGoHomeFirst() throws Exception {
+        final int paramNo = 0;
+        BeehiveWsParameterMetadata param = getParam("goHome", paramNo);
+        assertNotNull("Cannot find first param for method goHome();", param);
+        assertEquals("Invalid wpName;", "when", param.getWpName());
+        assertEquals("Invalid return type: " + param.getJavaType(),
+                long.class,
+                param.getJavaType());
+    }
+
+    protected BeehiveWsMethodMetadata getMethod(String methodName) {
+        for (BeehiveWsMethodMetadata method : ((BeehiveWsTypeMetadata) objectModel).getMethods()) {
+            if (method.getWmOperationName().equals(methodName)) {
+                return method;
+            }
+        }
+        return null;
+    }
+
+    protected BeehiveWsParameterMetadata getParam(String methodName, int pos) {
+        for (BeehiveWsMethodMetadata method : ((BeehiveWsTypeMetadata) objectModel).getMethods()) {
+            if (method.getWmOperationName().equals(methodName)) {
+                int i = 0;
+                for (BeehiveWsParameterMetadata param : method.getParams()) {
+                    if (i == pos) {
+                        return param;
+                    }
+                    i++;
+                }
+            }
+        }
+        return null;
+    }
+}

Propchange: incubator/beehive/trunk/wsm/drt/tests/org/apache/beehive/wsm/jsr181/model/FooTestCase.java
------------------------------------------------------------------------------
    svn:eol-style = native