Abstract
Model transformations are a fundamental part of Model Driven Engineering. Automated testing of model transformation is challenging due to the complexity of generating test models as test data. In the case of model transformations, the test model is an instance of a meta-model. Generating input models manually is a laborious and error prone task. Test cases are typically generated to satisfy a coverage criterion. Test data generation corresponding to various structural testing coverage criteria requires solving a number of predicates. For model transformation, these predicates typically consist of constraints on the source meta-model elements. In this paper, we propose an automated search-based test data generation approach for model transformations. The proposed approach is based on calculating approach level and branch distances to guide the search. For this purpose, we have developed specialized heuristics for calculating branch distances of model transformations. The approach allows test data generation corresponding to various coverage criteria, including statement coverage, branch coverage, and multiple condition/decision coverage. Our approach is generic and can be applied to various model transformation languages. Our developed tool, MOTTER, works with Atlas Transformation Language (ATL) as a proof of concept. We have successfully applied our approach on a well-known case study from ATL Zoo to generate test data.
This is a preview of subscription content, log in via an institution.
Buying options
Tax calculation will be finalised at checkout
Purchases are for personal use only
Learn about institutional subscriptionsPreview
Unable to display preview. Download preview PDF.
References
Baudry, B., Ghosh, S., Fleurey, F., France, R., Le Traon, Y., Mottu, J.M.: Barriers to systematic model transformation testing. Communications of the ACM 53(6), 139–143 (2010)
Ali, S., Iqbal, M., Arcuri, A., Briand, L.: Generating Test Data from OCL Constraints with Search Techniques. IEEE Transactions on Software Engineering 39(10), 26 (2013)
Fleurey, F., Baudry, B., Muller, P.A., Traon, Y.L.: Qualifying input test data for model transformations. Software and Systems Modeling 8(2), 185–203 (2009)
Wang, J., Kim, S.-K., Carrington, D.: Automatic generation of test models for model transformations. In: 19th Australian Conference on Software Engineering, ASWEC 2008. IEEE (2008)
Sen, S., Baudry, B., Mottu, J.-M.: Automatic model generation strategies for model transformation testing. Theory and Practice of Model Transformations, 148–164 (2009)
Vallecillo, A., Gogolla, M., Burgueño, L., Wimmer, M., Hamann, L.: Formal specification and testing of model transformations. Formal Methods for Model-Driven Engineering, 399–437 (2012)
Gómez, J.J.C., Baudry, B., Sahraoui, H.: Searching the boundaries of a modeling space to test metamodels. In: 2012 IEEE Fifth International Conference on Software Testing, Verification and Validation (ICST). IEEE (2012)
Cariou, E., Belloir, N., Barbier, F., Djemam, N.: OCL contracts for the verification of model transformations. In: Proceedings of the Workshop the Pragmatics of OCL and Other Textual Specification Languages at MoDELS (2009)
Guerra, E., de Lara, J., Wimmer, M., Kappel, G., Kusel, A., Retschitzegger, W., Schönböck, J., Schwinger, W.: Automated verification of model transformations based on visual contracts. Automated Software Engineering, 1–42 (2012)
Wang, W., Kessentini, M., Jiang, W.: Test Cases Generation for Model Transformations from Structural Information. In: 17th European Conference on Software Maintenance and Reengineering, Genova, Italy (2013)
Küster, J.M., Abd-El-Razik, M.: Validation of model transformations–first experiences using a white box approach. In: Kühne, T. (ed.) MoDELS 2006. LNCS, vol. 4364, pp. 193–204. Springer, Heidelberg (2007)
Büttner, F., Egea, M., Cabot, J.: On verifying ATL transformations using ‘off-the-shelf’SMT solvers. In: France, R.B., Kazmeier, J., Breu, R., Atkinson, C. (eds.) MODELS 2012. LNCS, vol. 7590, pp. 432–448. Springer, Heidelberg (2012)
González, C.A., Cabot, J.: ATLTest: A White-Box Test Generation Approach for ATL Transformations. In: France, R.B., Kazmeier, J., Breu, R., Atkinson, C. (eds.) MODELS 2012. LNCS, vol. 7590, pp. 449–464. Springer, Heidelberg (2012)
McQuillan, J.A., Power, J.F.: White-box coverage criteria for model transformations. In: Model Transformation with ATL, p. 63 (2009)
Mottu, J.-M., Sen, S., Tisi, M., Cabot, J.: Static Analysis of Model Transformations for Effective Test Generation. In: ISSRE-23rd IEEE International Symposium on Software Reliability Engineering (2012)
Ali, S., Iqbal, M.Z., Arcuri, A., Briand, L.: A Search-based OCL Constraint Solver for Model-based Test Data Generation. In: 2011 IEEE 11th International Conference on Quality Software, pp. 41–50 (2011)
Ali, S., Iqbal, M.Z., Arcuri, A.: Improved Heuristics for Solving OCL Constraints using Search Algorithms. In: Proceeding of the Sixteen Annual Conference Companion on Genetic and Evolutionary Computation Conference Companion (GECCO). ACM, Vancouver (2014)
Myers, G., Badgett, T., Thomas, T., Sandler, C.: The art of software testing. Wiley (2004)
Wu, H., Monahan, R., Power, J.F.: Metamodel Instance Generation: A systematic literature review. arXiv preprint arXiv:1211.6322 (2012)
McMinn, P.: Search - based software test data generation: A survey. Software Testing, Verification and Reliability 14(2), 105–156 (2004)
Bézivin, J., Schürr, A., Tratt, L.: Model transformations in practice workshop. In: Bruel, J.-M. (ed.) MoDELS 2005. LNCS, vol. 3844, pp. 120–127. Springer, Heidelberg (2006)
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2014 Springer International Publishing Switzerland
About this paper
Cite this paper
Jilani, A.A., Iqbal, M.Z., Khan, M.U. (2014). A Search Based Test Data Generation Approach for Model Transformations. In: Di Ruscio, D., Varró, D. (eds) Theory and Practice of Model Transformations. ICMT 2014. Lecture Notes in Computer Science, vol 8568. Springer, Cham. https://doi.org/10.1007/978-3-319-08789-4_2
Download citation
DOI: https://doi.org/10.1007/978-3-319-08789-4_2
Publisher Name: Springer, Cham
Print ISBN: 978-3-319-08788-7
Online ISBN: 978-3-319-08789-4
eBook Packages: Computer ScienceComputer Science (R0)