1 22 package org.jboss.test.webservice.admindevel; 23 24 import junit.framework.Test; 25 import org.jboss.test.webservice.WebserviceTestBase; 26 27 import javax.naming.InitialContext ; 28 import javax.xml.rpc.Service ; 29 30 35 public class ExplodedExampleTestCase extends WebserviceTestBase 36 { 37 38 public ExplodedExampleTestCase(String name) 40 { 41 super(name); 42 } 43 44 public void testHelloString() throws Exception 45 { 46 InitialContext iniCtx = getClientContext(); 47 Service service = (Service )iniCtx.lookup("java:comp/env/service/HelloService"); 48 Hello helloPort = (Hello)service.getPort(Hello.class); 49 50 String retStr = helloPort.helloString("Kermit"); 51 assertEquals("Hello Kermit!", retStr); 52 } 53 54 55 public static Test suite() throws Exception 56 { 57 return getDeploySetup(ExplodedExampleTestCase.class, "ws4ee-admindevel.jar, ws4ee-admindevel-client.jar"); 58 } 59 } 60 | Popular Tags |