Show TOC

Procedure documentationTesting a Web Service Operation Locate this document in the navigation structure

 

The Web service chosen for testing can contain many operations. Web Services Navigator (WS Navigator) allows you to select the operation you want to test. You can enter or load test data for the input parameters of the selected operation.

Prerequisites

You have selected the Web service that you want to test.

Procedure

  1. Choose the Operation step on the Service Test tab page.

  2. Choose the operation you want to test from the list in the Operations screen area.

    Note Note

    You can test the selected operation without entering test data manually. To do this, choose the Result step in the navigation area. This way WS Navigator uses the default values for the operation input parameters.

    End of the note.
  3. Choose Next to proceed to the Input Parameters step.

  4. Review the input parameters:

    • When the selected operation has input parameters, they appear as a tree structure in the Parameters screen area. WS Navigator displays an asterisk sign next to the required parameters and provides a field for entering values for them. By default, the optional elements are skipped.

    • When there is documentation available for an input parameter, you can access it using the corresponding link displayed to the right of the parameter.

    • To collapse or expand the whole structure, use the buttons at the right end of the toolbar in the top part of the Parameters screen area.

    • To show or hide separate elements of the tree structure, expand or collapse the corresponding tree branch.

  5. If you want to enter or modify the test data for the input parameters manually, you can do one or more of the following:

    • If you want to enter a value for an optional parameter you should deselect the corresponding Skip checkbox.

    • If you do not need to provide values for all parameters in a structure branch you can select the Skip checkbox for the root element of the branch.

    • To edit all input parameters, choose   Edit   Unskip All  .

    • To display only the required input parameters, choose   Edit   Reset  .

    • To test the operation without entering test data manually, choose   Edit   Skip All  .

      Thus WS Navigator uses the default values for the operation input parameters

    • You can copy and paste the entered data between elements by choosing corresponding option from the Change (Change) menu.

      You can do this for individual elements, for a branch in the tree structure, and for the entire structure.

    • To find a particular value entered for an input parameter, choose Find on the right end of the toolbar and use the forms and buttons that appear below the toolbar.

      You can also replace some or all of the found values with another value. Note that the search functionality is not case sensitive, and you cannot use search wildcards.

    Note Note

    If you plan to repeat the test with the same or similar test data set, you can save the test data you have currently entered. To do this, choose the Export button in the toolbar and select the folder in which the XML file with the test data should be saved. You can later use the saved file with the   Import   Test Data   option described below.

    End of the note.
  6. If you want to load the test data from a file you can do one of the following:

    • To import a test data file saved from a previous test of the operation, choose   Import   Test Data  .

    • To import test data from an existing test scenario file, choose   Import   Test Scenario  .

      You can specify a scenario test data file that contains test data both for the currently selected operation and for other Web services and operations. The importing tool selects only the test data for the currently tested Web service interface and operation. When the scenario file contains two or more sections with test data for the selected operation, the importing tool selects the test data in the first section from the beginning of the file. More information: Using Test Scenarios

    Note Note

    During the import, WS Navigator verifies the test data and imports only the matching parameters. Thus you can reuse the available test data sets. This is useful, for example, when you test Web services with similar interfaces, or when you test a Web service that is still in development.

    End of the note.
  7. Choose Next.

    If the service requires authentication you may need to provide a user name and password.

Result

The system sends the test data to the Web service. On successful completion of the test you can compare the test data and the results, save the test data for later usage, or add the current test to a test scenario.