
You can consume Web services in your test scripts, that is, you can call a Web service using the WEBSERVICE command. To test a Web service you require a proxy class in the eCATT system (see WSPROXY for calling a proxy in a remote system). This class can already exist in the eCATT system or you can generate it from a WSDL file. Inside a package, only one proxy class for each Web service is allowed.
For more information, see Consuming Web Services
Logical Ports
No logical ports are generated during the generation of proxy classes in current Releases. Instead, the parts that describe the target system and the service addressing parts are stored separately. A logical port is then generated at execution.
You can create and maintain logical ports in transaction SOAMANAGER.
For more information, see Logical Ports for Web Services .
Target Systems
The target system for a WEBSERVICE command uses an HTTP destination (type G for Java, type H for ABAP).
The use of the target system is to temporarily override the URL or HTTP destination in the logical port with the URL specified in the HTTP destination of the target system (in fact, eCATT makes a temporary copy of the logical port, and it is this copy that is used). A path suffix is necessary either in the destination, the logical port, or the command interface.
Only when using a target system does a path suffix in the command interface have an effect. It overrides other path suffixes.
Generating Proxy Classes
Choose Pattern .
In the Group field, choose Enterprise Services .
In the Command field, choose WEBSERVICE .
Assign a package and, if required, a transport request.
You should normally assign the generated objects to the same package as the test script. This will help ensure that they will be transported with the script that calls them.
Choose Continue .
Enter the URL for the WSDL web service definition.
You can use the F4 help to call up the WSIL browser to search for Web services on the ABAP stack of any system.
Choose Generate Proxy Class .
Select the PortType from the offered list (if several PortTypes exist).
Choose Continue .
If the proxy class already exists, it is regenerated.
In the ABAP Proxy Method field, select a method from the dropdown list.
Choose Continue .
Using an Existing Proxy Class
Choose Pattern .
In the Group field, choose Enterprise Services .
In the Command field, choose WEBSERVICE .
Choose Continue .
In the ABAP Proxy Class field, enter the name of the class.
In the ABAP Proxy Method field, select a method from the dropdown list.
Choose Continue .
Regenerating Proxy Classes
If a Web service changes, you will need to regenerate the proxy class.
Display the command interface of the Web service.
Choose
.
The system generates a new proxy class with a new name and copies it into the command interface.
Assign a transport request if necessary.
After you have regenerated the proxy class, restart eCATT.