Unit Test Processing

A unit test is an element "test" in a provtest file.

All the "inject" elements are executed first, followed by the "action" elements. An "inject" element triggers :
  • the creation of the service order or the file handle

  • a synchronous call to the "onPut" operation of the accurate module

An action can contain several sub-elements of the same type (several "create", several "invoke"). Those sub-elements must be given exactly in the order given in provtest schema. Some infraction of that rule may not be detected by the libxml2 at validation time, and may result in a sub-element being executed before some other while it is declared after.

For instance, in the following test, the execution sequence will be :
  • create the service order "1"

  • create the service order "2"

  • invoke the operation "some_operation"

<test name="test">
	  <action>
		 <createSo orderId="1"/>
			<invoke object="2" operation="some_operation"/>
		 <createSo orderId="2"/>
	  </action>
	</test>