OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

ebxml-iic message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: Latest Test Framework edits (re: GetMessage semantics)


Jacques and all,

Here is my edit for section 7.4 of the Test Framework Specification ( GetMessage Semantics ).  I've also attached the latest version of the spec with these edits.  I've also added an "Exception Condition" column on many XML content reference tables, to provide guidance to Test Driver implementers regarding how to handle special cases in scripting execution.

Regards,

Mike

 

Semantics of the GetMessage operation

A fundamental aspect of the GetMessage operation is its behavior and effect over the Message Store. 
The Message Store is an XML document object that contains an XML representation of all synchronous and asynchronously received ebXML messages for a Test Case. The received messages for a particular Test Case MUST persist in the Message Store  for the life of the Test Case. Messages in the Message Store MAY contain all MIME, SOAP and ebXML or other types of message content, represented as an XML document.  The particular XML representation of a message in the Message Store is based upon an  a "best practice" schema for representing a particular message type.  If the messages being stored are ebXML messages using HTTP transport and a SOAP envelope, the XML format of the Message Store document MUST validate against the ebXMLMessageStore.xsd schema in appendix D.

The GetMessage Filter sub-operation queries the Message Store document object, and retrieves (by default) the XML content that satisfies the XPath expression specified in its Filter child element.  As the MessageStore is updated every time a new message comes in, a GetMessage() operation will automatically execute as often as needed, until either (1) its Filter selects and returns a non-empty node-set, or (2) the timeout (stepDuration) expires.

The XPath query used as content for a Filter operation MUST yield a node-list of Message elements, as defined by the Message Store schema in Appendix XX.  Although the content of a message may vary (e.g. ebXML, RNIF, SOAP), all node-lists MUST contain Message elements.

Setting Parameters using received Message Content:

In addition to storing message content, the Message Store MAY also store parameter values to be used in the evaluation of subsequent received messages.  This is done through the SetXPathParameter operation.  Whether it is a message header, or an XML message payload being examined, the test writer may assign a parameter name, and an XPath pointing to the content to be stored as a parameter.    XPath parameters are stored in the Message Store, as defined in the Message Store schema in Appendix XX.  Each  parameter value is a string representation of the nodelist content retrieved by the XPath query.  The root node of the Message Store parameter list is a UUID identifyinig the instance of the Test Case currently being executed.

 A TestPreCondition and/orTestAssertion sub-operation ( which also contain a single XPath query) query the resulting document object constructed from the node-list generated by a GetMessage Filter operation. That document object to be examined by a TestPreCondition of TestAssertion action MUST have a root element with a name of test:Result ( as defined in the Result schema in Appendix XX).   If the Test Driver is unable to create a Result document object because the resulting node-list contains any XML content other than Message elements ( such as an attribute list), then the Test Driver MUST generate an exception, and terminate the Test Case with a result of "undetermined".  (i.e. if the XPath query does not return XML content that can be built into a document object, then it cannot be further examined with XPath in the TestPreCondition or TestAssertion operations)

Message Masking:

        All the message items available for querying, are children of the MessageStore element. The Xpath expression in the Filter will typically select all the /MessageStore/Message elements that satisfy the filter, and these will be consolidated as children of a Result element, available for further querying, e.g. by the TestAssertion operation.

        The messages that have been selected by a GetMessage() operation are "invisible" to future Getmessage() operations in the same test case, unless the "mask" attribute is set to "false" (default is "true"). A GetMessage() operation will query all messages in the message store for this test case, except those messages that have been masked by a previous GetMessage() operation. 

How message masking takes place in a Test Driver is implementation specific.




 

testframework_1.1_03_01_04.zip



[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]