6.13 Create Assert Dialog

Use to select the type of assertion to perform. If the operation supports only input messages, the Assert Input button is enabled. If the operation supports both input and output messages, the Assert Input and Assert Output buttons are enabled.

Element Description

Assert Input

Select to create an assertion in the inbound direction.

Assert Output

Select to create an assertion in the outbound direction.

Assert Callback

Select to create a callback assertion.

Assert Fault

Select to assert a fault into the application flow.

Callback Operation

Select the type of callback to assert. This field only displays if you select Assert Callback.

Fault

Select the type of fault to assert (for example, NegativeCredit). This field only displays if you select Assert Fault.

Assert Target

Displays the type of assert target you selected (either an entire XML document, part section of a message, nonleaf element, or leaf element).

Compare By

Select the type of comparison to perform. The selections that display are based upon the type of assertion you selected.

For leaf element assertions, select the type of comparison:

  • string: Compares string values

  • number: Compares numerical values

  • pattern-match: Compares a regular expression pattern (for example, [0-9]*). Java Development Kit (JDK) regular expression (regexp) constructs are supported. For example, entering a pattern of ab[0-9]*cd means that a value of ab123cd or ab456cd is correct. An asterisk (*) indicates any number of occurrences.

For entire XML document assertions, part section assertions, or nonleaf assertions, specify the strictness of the comparison.

  • XML Identical: Used when the comparison between the elements and attributes of the XML documents must be exact. If there is any difference between the two XML documents, the comparison fails. For example, the comparison fails if one document uses an element name of purchaseOrder, while the other uses an element name of invoice. The comparison also fails if the child attributes of two elements are the same, but the attributes are ordered differently in each element.

  • XML Similar: Used when the comparison must be similar in content, but does not need to exactly match. For example, the comparison succeeds if both use the same namespace Uniform Resource Identifier (URI), but have different namespace prefixes. The comparison also succeeds if both contain the same element with the same child attributes, but the attributes are ordered differently in each element.

    In both of these examples, the differences are considered recoverable, and therefore similar.

Assert Value

If you selected to perform a variable assertion, enter the value you are expecting.

Message Parts

If you selected to perform an assertion of an entire XML document, part section of a message, or nonleaf element, enter the following details:

Part

Select the message part containing the fault (for example, payload).

Value

Create a simulated fault message to return from a web service partner in either of two ways:

Enter Manually

Click to manually enter message data in the Enter Value field. The Generate Sample button enables you to automatically generate a sample file for testing. Click Save As to save the sample file.

Load From File

Click to access the Browse icon for loading message data from a file. The file is added to the messages folder in the Application Navigator.

Description

Enter an optional description.

Related Topics

Editing the Contents of Test Cases in Test Mode in the SOA Composite Editor in Developing SOA Applications with Oracle SOA Suite