FileDocCategorySizeDatePackage
Import3TestCase.javaAPI DocApache Axis 1.43601Sat Apr 22 18:57:28 BST 2006test.wsdl.interop3.import3

Import3TestCase

public class Import3TestCase extends TestCase

Fields Summary
public static URL
url
Constructors Summary
public Import3TestCase(String name)

        super(name);
    
Methods Summary
public static voidmain(java.lang.String[] args)

        if (args.length == 1) {
            try {
                url = new URL(args[0]);
            } catch (Exception e) {
            }
        }

        junit.textui.TestRunner.run(new junit.framework.TestSuite(Import3TestCase.class));
    
public voidtestStep3EchoStruct()

        SoapInteropImport3PortType binding;
        try {
            if (url == null) {
                binding = new Import3Locator().getSoapInteropImport3Port();
            } else {
                binding = new Import3Locator().getSoapInteropImport3Port(url);
            }
        }
        catch (javax.xml.rpc.ServiceException jre) {
            throw new junit.framework.AssertionFailedError("JAX-RPC ServiceException caught: " + jre);
        }
        assertTrue("binding is null", binding != null);

        try {
            SOAPStruct value = new SOAPStruct();
            value.setVarString("import2 string");
            value.setVarInt(5);
            value.setVarFloat(4.5F);
            SOAPStruct result = binding.echoStruct(value);
            assertEquals("String members didn't match", value.getVarString(), result.getVarString());
            assertEquals("int members didn't match", value.getVarInt(), result.getVarInt());
        }
        catch (java.rmi.RemoteException re) {
            throw new junit.framework.AssertionFailedError("Remote Exception caught: " + re);
        }
    
public voidtestStep3EchoStructArray()

        SoapInteropImport3PortType binding;
        try {
            if (url == null) {
                binding = new Import3Locator().getSoapInteropImport3Port();
            } else {
                binding = new Import3Locator().getSoapInteropImport3Port(url);
            }
        }
        catch (javax.xml.rpc.ServiceException jre) {
            throw new junit.framework.AssertionFailedError("JAX-RPC ServiceException caught: " + jre);
        }
        assertTrue("binding is null", binding != null);

        try {
            SOAPStruct[] value = null;
            value = binding.echoStructArray(new SOAPStruct[0]);
        }
        catch (java.rmi.RemoteException re) {
            throw new junit.framework.AssertionFailedError("Remote Exception caught: " + re);
        }