Java Reference
In-Depth Information
Testing a Deployed BPEL Process
Problem
You want to create and run tests against the BPEL process that you deployed using a CASA
project in NetBeans.
Solution
Create a new test case and point to the process WSDL. You'll be asked what operation you
want to test, and the IDE will generate a SOAP message that will serve as input to the opera-
tion.
Discussion
Unlike unit tests, these test cases generate SOAP messages that match your WSDL, and just
know how to invoke your service behind the scenes. Following are step-by-step instructions
for creating a new SOAP test for your BPEL process.
NOTE
This recipe expects that you have created the process from Creating a BPEL Process That Invokes a
Partner and deployed it as shown in Deploying a BPEL Process to OpenESB's BPEL Service Engine .
However, the general idea is the same for any deployed BPEL process.
Creating the test
Within your CustomerCASA project, right-click on the Test folder and choose New Test Case.
Enter a name of “TestHomer” for the test case and click Next. Homer is the name of the cus-
tomer you expect to get back given the ID you'll supply.
You should now see the WSDL Document Selection screen, showing a selection of possible
WSDL documents based on your project. Drill down to Customer Process→Source Packages
and select the CustomerProcessEsb.wsdlfile. This is the file that represents the client-facing
BPEL process, and that's what you want to invoke. Click Next.
The wizard will read the WSDL file and present you with a selection of possible operations
that you could invoke with the test you are creating. You only have one operation in this ex-
ample, so choose it: CustomerProcessEsbOperation. Click Finish.
Search WWH ::




Custom Search