ActiveVOS Designer User’s Guide

Example BUnit File

Here is a BUnit source template, showing most of the sections of a BUnit file.

<?xml version="1.0" encoding="UTF-8"?>
<abu:bpelUnit xmlns:abu="http://schemas.active-endpoints.com/activebpelunit/2008/10/activebpelunit.xsd" 
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
   <abu:trace>on</abu:trace>
   <abu:engineProperties>
      <abu:documentation>Controls engine configuration options, including process logging.</abu:documentation>
      <abu:engineProperty path="Logging" value="urn:ae:execution"/>
   </abu:engineProperties>
   <abu:bpels>
      <abu:documentation>Controls deployment of the BPEL process to the test engine.</abu:documentation>
      <abu:bpel location="../bpel/loanProcessHumanCompleted.bpel"/>
   </abu:bpels>
   <abu:wsdls>
      <abu:documentation>Controls deployment of the WSDL files to the test engine.</abu:documentation>
      <abu:wsdl location="../wsdl/loanProcess.wsdl"/>
   </abu:wsdls>
   <abu:schemas>
      <abu:documentation>Controls deployment of the XML Schema files to the test engine.</abu:documentation>
      <abu:schema location="../schema/loanRequest.xsd"/>
   </abu:schemas>
   <abu:resources>
      <abu:documentation>Controls deployment of resource mappings to the test engine.</abu:documentation>
      <abu:resource location="../xsl-renderings/loan_taskdetail.xsl" locationHint="project:/humantaskcompleted/xsl-renderings/loan_taskdetail.xsl" type="http://www.w3.org/1999/XSL/Transform"/>
      <abu:resource location="../xsl-renderings/loan_param2commands.xsl" locationHint="project:/humantaskcompleted/xsl-renderings/loan_param2commands.xsl" type="http://www.w3.org/1999/XSL/Transform"/>
   </abu:resources>
   <abu:invokes>
      <abu:documentation>Defines the simulated output and assertions to perform on invoke activities</abu:documentation>
      <abu:invoke count="1" name="NotifyCRMOfExpiration">
         <abu:invokeIteration index="0"/>
      </abu:invoke>
     
   </abu:invokes>
   <abu:commands>
      <abu:documentation>Sends messages to the BUnit test engine to execute the test logic.</abu:documentation>
      <abu:sendMessage async="true" operation="request" partnerLink="LoanProcess">
         
      </abu:sendMessage>
      <!-- Tells the test to wait before making final assertions -->
      <abu:waitUntil xmlns:ns="http://docs.active-endpoints.com/sample/bpel/loanprocess/2008/02/loanProcessHumanCompleted.bpel" processName="ns:loanProcessHumanCompleted" timeout="5000"/>
   </abu:commands>
</abu:bpelUnit>