Show TOC

Importing Test Data from a URLLocate this document in the navigation structure

Use

Web Services Navigator (WS Navigator) allows you to accelerate the process of testing Web service operations. Instead of manually choosing a Web service, selecting operation and entering test data, you can provide all this information to WS Navigator at once and view the test results immediately. To do this, you should include the necessary information in the form of parameters in a dedicated URL, and use this URL in a Web browser.

Passing the test information via URL can be useful in situations such as the ones described below:

  • You want to perform several tests of a particular Web service operation with different sets of test data.

    You can do this by simply changing the address of the file containing the test data.

  • You develop an application or a Web page for managing Web services, and you want to provide a link for testing the displayed Web service operation in WS Navigator.

    This way, users can instantly view how the Web service works and decide if it is suitable for their needs.

Features

The URL for starting WS Navigator should begin in the following way: http://<host>:<port>/webdynpro/dispatcher/sap.com/tc~esi~esp~wsnav~ui/WSNavigator?

You should use the proper values for the host and port of the system where WS Navigator is available.

The parameters for testing should be added next. For each of these parameters, you should use the parameter=value syntax. When using more than one parameter, you need to separate the parameters with the & (ampersand) character. You can include the following parameters in the URL:

  • Use wsdl to provide the URL of the WSDL of the Web service you want to test.

  • Use operation to specify the operation name.

    Consider that this value is case sensitive.

  • Use testdata to provide the URL of the file containing the test data for the specified Web service operation.

  • Use execute with a true value if you want WS Navigator to start the test.

Example

You can perform a test by entering the following URL in a Web browser: http://test.example.com:50000/webdynpro/dispatcher/sap.com/tc~esi~esp~wsnav~ui/WSNavigator?wsdl=http://myservice.example.com:50000/irj-fpn-ws/CommunicationChannelService?wsdl&operation=transferData&testdata=http://data.example.com/testdata/transferData.xml&execute=true

In this example, the URL consists of the following elements:

  • http://test.example.com:50000/webdynpro/dispatcher/sap.com/tc~esi~esp~wsnav~ui/WSNavigator shows that you want to perform the test using WS Navigator that runs on the test.example.com system.

  • wsdl=http://myservice.example.com:50000/irj-fpn-ws/CommunicationChannelService?wsdl shows that you want to test the CommunicationChannelService Web service deployed on the myservice.example.com system.

  • operation=transferData shows that you want to test the transferData operation.

  • testdata=http://data.example.com/testdata/transferData.xml shows that you want to use the test data available in the specified transferData.xml file.

  • execute=true shows that you want WS Navigator to start the testing immediately.