3 CHECKING PATHS IN BPEL
PROCESSES
The procedure of generation of a set of test cases for
BPEL process consists of the following steps:
1. formalization of functional requirements for the
process and writing down this formalization with
the help of notation SCR (Software Cost
Reduction (Heitmeyer, 1997)); to this end
a. determine all atomic functional requirements
R
Id
for the process,
b. determine Web services which will be used,
c. declare a pair of ports in/out for each of the
service,
d. declare variables related to the output ports,
e. declare variable state; values of state will say
how the process is advanced,
f. determine values of variable state,
2. design of an automaton modeling the process
and its validation; to this end
a. determine states of the process: a state of the
process is determined by a value of variable
state, values of variables related to output
ports and values of internal variables of the
process,
b. define next-state table for state variable; in
each row of the table add information about
specification requirements R
Id
and tasks of
Coordinator checked when transition
corresponding to the row is executed,
c. define tables of values for remaining
variables, in each row of the table add
information about specification requirements
R
Id
and tasks of Coordinator checked when
the process reached the state corresponding to
the row.
3. formalization of temporal requirements for the
process and writing down this formalization with
the help of notation SCR; to this end
a. determine all atomic temporal constraints CId
for the process,
b. define a table of temporal constraints related
to the behavior of the automaton designed in
step 2.
4. development of Functional Requirements Graph
(FRG) for the process; to this end the automaton
designed in step 2 and the table defined in step 3
are used,
5. derivation of Test Scenario Tree (TST) from
FRG, and finally
6. generation a set of test cases from TST and FRG.
A set of test cases generated with the help of the
procedure guarantees that each functional path
(associated with functional requirement) and each
critical path (associated with temporal constraint) is
checked at least once. For BPEL process functional
requirements concern services and their
coordination. A schedule of the process results in
temporal constraints.
4 EXAMPLE
The following example of Order Booking (OB)
process illustrates the above procedure.
Table 1: Functional requirements for OB process.
R
Id
Description
R
1
When OrderBookingESB sends information about order
(a) BPEL process calls CustomerService to retrieve
customer ID, name, address and credit card information
(b). Now BPEL process can check the identified
customer against VerifyClient Service to verify the
customer’s credit card is valid. If the credit is not
approved, the process cancels the order and sends the
customer an email by NotificationService (c). Otherwise
if credit is approved (d), the process takes the order
amount, customer status and runs DecisionService to
determinate if the order requires approval by
management. If the order is approved, it is sent to two
suppliers for their price quotes (e). The BPEL process
collects the quotes and selects the lowest quoted price
and the supplier which to award the order, then BPEL
process invokes FulfillmentESP which complete the
order (f). Once the order is fulfilled, the BPEL process
sets the order to complete and starts NotificationService
which sends an email with the purchase order
information (g). When the email is sent the BPEL
process closes the order (h).
R
2
When OrderBookingESB sends the order information,
the data is sent to CustomerService (a). When
CustomerService retrieves customer ID, name, address
and credit card information BPEL process closes the
connection with CustomerService (b)
R
3
When the CustomerService retrieves customer ID, name,
address and credit card information BPEL process can
check the identified customer against VerifyClient
Service where the data is sent (a). When VerifyClient
Service retrieves disapproval (b) or approval (c) BPEL
process closes the connection with VerifyClient Service
R
4
When credit is approved BPEL process run
DecisionService to determinate if the order requires
approval by management (a). When decision is retrieved
BPEL process closes the connection with
DecisionService (b).
R
5
When the decision is retrieved BPEL process sends the
order to SelectManufacturer supplier for his price quote
(a). When BPEL process collects the quote it closes the
connection with SelectManufacturer service (b).
R
6
When the decision is retrieved BPEL process sends
order to RapidService supplier for his price quote (a).
When BPEL process collects the quote it closes the
connection with SelectManufacturer service (b).
R
7
When the BPEL process collects the quotes then invokes
FulfillmentESP which completes the order (a). Once the
order is fulfilled the connection with FulfillmentESP is
closed (b).
R
8
When the order is fulfilled, the BPEL process starts
NotificationService (a) which sends an email to the
client. When it is done, BPEL process closes the
connection with Notification Service (b).
ICEIS 2008 - International Conference on Enterprise Information Systems
382