Abstract

A key component of model-based testing is the generation of test data from constraints (e.g., specified in the Object Constraint Language (OCL)) associated with models e.g., specified in the Unified Modeling Language (UML). The quality of test data eventually determines the effectiveness of test cases, e.g., fault detection and coverage. A simple way to generate test data from an OCL constraint is to find a set of values for all the variables that satisfies the constraint. One way of improving the quality of test data is by generating test data at the boundaries of each variable in the constraint. In this paper, we extend our search-based test data generation approach to generate test data at the boundaries of each variable involved in a constraint. We present different cases of constraints involving different types of variables and how we rewrite them in order to automatically generate boundary values using our existing OCL Solver called EsOCL based on a set of heuristics. We empirically evaluated our heuristics using three search algorithms, i.e., Genetic Algorithm, (1+1) Evolutionary Algorithm, and Alternating Variable Method, on industrial OCL constraints from our previous work. Results show that AVM on average achieved a 95% of success rate and outperformed the rest of the algorithms in finding all the boundary values of constraints in fewer generations.

Full Text
Paper version not known

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call

Disclaimer: All third-party content on this website/platform is and will remain the property of their respective owners and is provided on "as is" basis without any warranties, express or implied. Use of third-party content does not indicate any affiliation, sponsorship with or endorsement by them. Any references to third-party content is to identify the corresponding services and shall be considered fair use under The CopyrightLaw.