WSDL message properties

As part of web services testing, you can configure how content in the XML or SOAP message is managed, by viewing and editing the WSDL message properties.

Operation header properties

Each operation that is contained within the WSDL file defines a set of header properties that can be sent with the message. During the processing of the WSDL file, these properties are extracted from the operation and when a message for an operation is selected, these properties are automatically added to the header properties of the Rational® Integration Tester message. These properties generally consist of the content-type of the message (usually XML or text) and the SOAP action.

SOAP Faults

When a web service request generates an error within the server, the server sends a response message that contains a SOAP Fault element instead of a SOAP Body element. This SOAP Fault is defined within the SOAP Envelope XML schema definition. When a SOAP Fault is received, both the RPC-Encoded and the Document-Literal Formatters generate a Rational® Integration Tester message that has the same structure. They both extract the SOAP Fault element and generate a standard XML Message structure in the same manner as the XML Text Message Formatter. Because SOAP Faults are not defined within the WSDL file, they are managed by using the standard XML schema process.

Within Rational® Integration Tester, you can define an XSD schema that references a SOAP Envelope XML schema definition. There are several of these definitions and they can vary from each other.

You can select the SOAP Envelope that contains the SOAP Fault definition that is expected. If it is expected that a SOAP Fault is to be returned from a request, then within the received request, you can select the required SOAP Envelope XSD as the schema for the message. Then, you can select the Fault root and build the expected structure with the required validation.

XML and SOAP message properties

By using the message properties in Rational® Integration Tester, you can configure how the content in a message is managed in test actions (for example, Publish, Subscribe). You can view or modify message properties by right-clicking the root of the SOAP message in the requirement or in the body of the message editor.

Message editor

You can use the Field Properties dialog box to view or edit the message properties.

XML field properties
Tip: You can click Preview any time to view the message as it is applied by using the properties that you modified.

The tabs that you can configure in the Field Properties dialog box are as follows:

XML

In the XML tab, you can configure how to manage XML content in the message.

XML properties
Each option is described in the following table:
Table 1. XML properties
Option Description
Formatting The XML is formatted either as a Single-line or as a Multi-line indented message.
Encoding The character encoding that must be used and is included in the XML Declaration, if present.
Normalize the document In the XML, extra spaces are removed.
Send NULL values Whether Elements, Attributes, or Comments with null values are included in the generated XML.
Include XML Declaration The XML declaration is included at the beginning of the message.
Treat CDATA as Text When processing, CDATA nodes are converted to Text nodes.
Preserve whitespace Controls whether the root node default for xml:space is set to preserve.
Tip: You can modify the default values for the XML options by using the Preferences window in Rational® Integration Tester (Window > Preferences, then select the XML option).

SOAP headers

In the SOAP Headers tab, you can enable or disable the sending of SOAP headers with the message, and display any headers that are included in the current message.SOAP Headers
You can select or clear the Enable check box to toggle to include the SOAP headers in the current message.
Tip: You can specify the default settings for SOAP headers by using the Preferences window in Rational® Integration Tester (Window > Preferences, then select the SOAP option).

SOAP

In the SOAP tab, you can specify the version of SOAP (1.1 or 1.2) and specify other parameters that can be applied in the message.SOAP field properties
You can configure the SOAP message by selecting the SOAP version from the list, specifying the namespace URI to be used inside the body of the message. The namespace that you specify overrides the body namespace URI but is not displayed in the preview when you click Preview from the XML tab.
Restriction: The namespace you specify is applied only to the RPC-encoded messages.
Tip: You can add any number of custom namespaces with prefixes in the SOAP Headers (by adding Child Attributes). To override the namespace URI in the Body element you must right-click the Value holder node (token) and then select the xmlns:tns option to provide a custom namespace URI for the Body element.
If you do not want the default prefix to be applied, you can specify an envelope namespace prefix for the message in the Envelope Namespace Prefix field. The default SOAP envelope namespace prefix used for SOAP 1.1 message is SOAP-ENV and SOAP 1.2 message is env.
Tip: You can specify the default settings for SOAP by using the Preferences window in Rational® Integration Tester (Window > Preferences, then select the SOAP option).

WS-Addressing

In the WS-Addressing tab, you can enable or disable message constructs (that includes endpoints and information headers) to send with the SOAP message. You can also modify the WS-Addressing properties to be sent.
Tip: You can enable or disable the sending by default of the WS-Addressing constructs in the Preferences window in Rational® Integration Tester (Window > Preferences, then select the WS-* Extensions option).

WS-Security

In the WS-Security tab, you can enable or disable WS-Security actions to send with the SOAP message.
Tip: You can enable or disable the sending of WS-Security actions by default in the Preferences window in Rational® Integration Tester (Window > Preferences, then select the WS-* Extensions option).