generating test cases specifications for bpel compositions of web services using spin
Download
Skip this Video
Download Presentation
Generating test cases specifications for BPEL compositions of web services using SPIN

Loading in 2 Seconds...

play fullscreen
1 / 21

Generating test cases specifications for BPEL compositions of web services using SPIN - PowerPoint PPT Presentation


  • 75 Views
  • Uploaded on

Generating test cases specifications for BPEL compositions of web services using SPIN. José García-Fanjul, Javier Tuya, and Claudio de la Riva Pointner Stefan 13.01.2014. Contents. Introduction Specification of web services compositions with BPEL

loader
I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
capcha
Download Presentation

PowerPoint Slideshow about 'Generating test cases specifications for BPEL compositions of web services using SPIN' - teness


An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
generating test cases specifications for bpel compositions of web services using spin

Generating test cases specifications for BPEL compositions of web services using SPIN

José García-Fanjul, Javier Tuya, and Claudio de la Riva

Pointner Stefan

13.01.2014

AK Softwaretechnologie 1 WS 2013/14

contents
Contents
  • Introduction
  • Specification of web services compositions with BPEL
  • Overview of the generation of test cases specifications
  • Transforming BPEL specifications into PROMELA
  • Using SPIN to generate test case specifications
  • Conclusion

AK Softwaretechnologie 1 WS 2013/14

introduction
Introduction
  • Web as a Commercial Channel
  • Certain exchange protocol  XML
  • Software with XML as Input and Output
  •  XML based Web Services
    • Distributed
    • Asynchronous
    • Platform independent
    • Low coupled

AK Softwaretechnologie 1 WS 2013/14

introduction1
Introduction
  • Compositions of Web Services
    • Business Process Execution Language (BPEL)
  • Testing Web Services
    • Asynchronous behavior
    • Distribution
    • Availability
    • Lack of user Interface

AK Softwaretechnologie 1 WS 2013/14

specification of ws with bpel
Specification of WS with BPEL
  • XML-Documents
    • Declarations
    • Specifications
  • Declarations
    • Partners
    • Variables
  • Specification
    • Basic Activities (Assign, Invoke, Receive)
    • Structured Activities (Sequence, Flow, While)

AK Softwaretechnologie 1 WS 2013/14

bpel example
BPEL Example

AK Softwaretechnologie 1 WS 2013/14

slide7

messageType="asns:riskAssessmentMessage"/>

[...]

[...]

[...]

...

AK Softwaretechnologie 1 WS 2013/14

business process
Business Process

AK Softwaretechnologie 1 WS 2013/14

test case specification generation
Test case specification generation
  • Simple PromelaInterpreter – SPIN
    • LTL Formulae used for Property-specification
    • How it works?
      • SPIN searches all possible states within the model
      • Checks whether the properties hold
      • If not  gives a Counter Example
    • Generate Test Cases with SPIN
      • Transform Counter Example to Test Cases
  • Process/Protocol Meta Language – PROMELA
    • Describes models of distributed Systems

AK Softwaretechnologie 1 WS 2013/14

test case specification generation1
Test case specification generation
  • Composition Under Test (CUT) is transformed into PROMELA
  • Transitions are identified
  • Mapping Transitions onto the Model
  • Transition expressed as LTL Property
  • Run SPIN with the Model and the Input LTL-Properties
  • Generate Test Cases with the produced Counter Example

AK Softwaretechnologie 1 WS 2013/14

test case specification generation2
Test case specification generation

AK Softwaretechnologie 1 WS 2013/14

transforming bpel specifications into promela
Transforming BPEL specifications into PROMELA
  • PROMELA also includes BPEL-partners
  • BPEL portTypes transformed to PROMELA message channels
    • chanloanassessor_riskPort_IN = [QLENGTH] of {byte, byte, byte};
    • Input and Output channel
    • Message Types are declared as typedefs
  • Invoke Activity = !
  • Receive Activity = ?

AK Softwaretechnologie 1 WS 2013/14

transforming bpel specifications into promela example
Transforming BPEL specifications into PROMELA - Example

BPEL_loanApprovalPort_OUT! approvalInfo.accept

  • Sends a messagecontainingthe variable approvalInfo.accept
  • tochannelBPEL_loanApprovalPort_OUT

AK Softwaretechnologie 1 WS 2013/14

transforming bpel specifications into promela web service
Transforming BPEL specifications into PROMELA – Web Service
  • If the BPEL specification has no reference to the data, it will be given an undefinedvalue
  • If the data is compared to a numerical constant, it will be given the value of the constant, a lower value and a higher third value
  • If the data is discrete, it will be given each of the discrete constants in the BPEL specification and a value different from them, called other

AK Softwaretechnologie 1 WS 2013/14

transforming bpel specifications into promela transitions
Transforming BPEL specifications into PROMELA – Transitions
  • BPEL is modelled in PROMELA
  • transitions are identified in the specification and are mapped within the model
  • Implicit Transitions
    • Invoke
    • Flow
    • While
  • Explicit Transitions
    • Are identified from link constructs
    • Explicitly transitions between activities (with same source or target)

AK Softwaretechnologie 1 WS 2013/14

slide17
Using SPIN to generate test case specifications
  • Transition expressed as LTL Property
    • Unique Boolean variables tran1, tran2, tran3, …
    • Variable will get true in case of the transition being exercised by the model checker
    • The variable associated with a transition X is always false [] !tranX
    • Test Case stop if the property tranX is false
    • To get to end, change property to:
      • [] ( !tranX || !bpel_ends)

AK Softwaretechnologie 1 WS 2013/14

using spin to generate test case specifications
Using SPIN to generate test case specifications
  • LTL property: [] ( !tran1 || !bpel_ends)
  • Example CounterExample for Transition 1, 3, 5:

customer: request.amount = 3

customer: BPEL_loanApprovalPort_IN!request

bpel: request.amount<4

bpel: tran1 = true

bpel: loanassessor_riskAssessmentPort_IN!request

assessor: riskAssessment.risk = low

assessor: loanassessor_riskAssessmentPort_OUT! riskAssessment

bpel: tran3 = true

bpel: approvalInfo.accept = yes

bpel: tran5 = true

bpel: BPEL_loanApprovalPort_OUT!approvalInfo

bpel: bpel_ends = true

  • Transformed into TestCase:
    • Input: Customer requests for an amount of 3 (less than four)
    • Input: Assessor sets risk to low
    • Output: reply to Customer is affirmative

AK Softwaretechnologie 1 WS 2013/14

using spin to generate test case specifications1
Using SPIN to generate test case specifications
  • Full transition coverage with three executions:
    • {1, 3, 5}
    • {1, 4, 6}
    • {2, 6}

AK Softwaretechnologie 1 WS 2013/14

conclusion
Conclusion
  • Generate test case specification from BPEL composition of web services
  • Method relies on SPIN Model Checker
    • Repeat execute to get a test suite for transition coverage
  • Independence from the particular implementation, only BPEL specification as input needed

AK Softwaretechnologie 1 WS 2013/14

any questions
Any Questions?

José García-Fanjul, Javier Tuya, and Claudio de la Riva. Generating testcasesspecificationsfor BPEL compositionsof web servicesusing SPIN. In Antonia Bertolinoand Andrea Polini, editors, in Proceedingsof International Workshop on Web Services Modeling andTesting (WS-MaTe2006), pages 83-94, Palermo, Sicily, ITALY, June 9th 2006.

AK Softwaretechnologie 1 WS 2013/14

ad