1 / 11

Test Generation with Abstraction and Concretization

Test Generation with Abstraction and Concretization. Jens R. Calamé Natalia Ioustinova Jaco van de Pol. Abstraction and test generation from platform independent models Starting point: UML-Model Formalization and abstraction of the specification before test generation.

draco
Download Presentation

Test Generation with Abstraction and Concretization

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. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Test Generation with Abstraction and Concretization Jens R. Calamé Natalia Ioustinova Jaco van de Pol

  2. Abstraction and test generation from platform independent models Starting point: UML-Model Formalization and abstraction of the specification before test generation Generation of parameterizable test cases on a platform-independent level Generation of Rules for Data Selection PIM PIT Our Approach in Context with MDA PSM PST Code TestCode 1st Dutch Workshop on Formal Testing Techniques

  3. PIM PIT Our Test Generation Process System Specification (informal) System Specification (formal) Abstraction Abstract System Specification Test Case Generation TGV Abstract Test Case Test Purpose TTCN-3 Generation Constraint Generation Parameterizable Test Case (TTCN-3) Rule System for Data Selection 1st Dutch Workshop on Formal Testing Techniques

  4. Abstraction • Motivation: Test Generation with TGV is based on enumerative techniques • Given: formal specification with infinite state-space w.r.t. input data • Result: formal specification with finite state-space w.r.t. input data • System abstraction on specification-level: • Replace all input values by one constant chaos (*) • Propagate this * through the system • Transform conditions based on * to nondeterministic choice Abstracted system is an over-approximation of original system 1st Dutch Workshop on Formal Testing Techniques

  5. Implementation of Abstraction Program transformation of a µCRL process specification: • For each datatype D add one additional type D* with • the constructor *D and • a lifting function :DD* • For all datatypes D realize all functions additionally for D* and lift them (strict lifting, except for datatype Boolean) • Lift all action and process parameters • Replace all input variables in the process definition by *(propagation of * happens automatically) and lift conditions • In the process initialization use • original values, lifted by , or • use * 1st Dutch Workshop on Formal Testing Techniques

  6. Our Test Generation Process System Specification (informal) System Specification (formal) Abstraction Abstract System Specification Test Case Generation TGV Abstract Test Case Test Purpose TTCN-3 Generation Constraint Generation Parameterizable Test Case (TTCN-3) Rule System for Data Selection 1st Dutch Workshop on Formal Testing Techniques

  7. Test Case Generation with TGV • TGV: Test Generation with Verification Technology • Part of CADP toolkit • Link between µCRL toolkit and CADP toolkit • Test Generation with TGV • Based on a labeled transition system (enumeration of all data values) • Guided by a test purpose (focus of generated test cases) 1st Dutch Workshop on Formal Testing Techniques

  8. Our Test Generation Process System Specification (informal) System Specification (formal) Abstraction Abstract System Specification Test Case Generation TGV Abstract Test Case Test Purpose TTCN-3 Generation Constraint Generation Parameterizable Test Case (TTCN-3) Rule System for Data Selection 1st Dutch Workshop on Formal Testing Techniques

  9. Generation of Data Selection Rules • Given: • Abstract test case(control flow information + internal data) • Original specification (data dependencies) • Result: (generated Prolog implementation) • Rules, representing ADT functions of the original specification (meta language) • Rule system based on specification: one rule for each transition in original system, containing • Conditions • Assignments (internally or from input actions, resp.) • Test oracle based on abstract test case(query to rule system) • Invocation of all selected actions as a conjunction 1st Dutch Workshop on Formal Testing Techniques

  10. Case Study CEPS • Common Electronic Purse Specifications • Standard for electronic payment cards and infrastructure • Appropriate to experimenting with our approach due to its data orientation • Experience with CEPS (card application) • Abstracted system of a challenging size (17.5 mio. transitions and 3 mio. states) • Size could be reduced further with unused variable analysis and LTS minimization(5487 transitions and 1627 states) From the resulting system, test cases and data constraints could be generated easily 1st Dutch Workshop on Formal Testing Techniques

  11. Conclusion and Future Work • Conclusion • *-Abstraction algorithm is implemented for µCRL • TGV is applied on abstracted systems • Parameterization constraint generation is defined and implemented • The whole test generation process is applied to the CEPS case study • Future work • Generation of parameterizable TTCN-3 test cases • Formalization of UML-Models for test generation • Comparison of STG to our approach (First release of STG: Oct. 2005) 1st Dutch Workshop on Formal Testing Techniques

More Related