Abstract
Automated generation of test data is an important and challenging activity in Model-based Testing. This typically requires solving of constraints, written in Object Constraint Language (OCL), specified on models in order to obtain solutions that can be used as test data. Test data generation techniques in the literature discuss various coverage criteria for test generation to achieve a sufficient level of coverage. One of the recommended criteria is modified condition/decision coverage (MC/DC) that is a requirement of different safety standards, such as DO-178C. In this paper, we propose a search-based strategy that utilizes case-based reasoning (CBR) to reuse the already generated test data and generate new test data that provides MC/DC coverage of OCL constraints. To evaluate the performance of the proposed approach in solving MC/DC constraints, we perform an empirical evaluation using AVM without CBR, AVM with CBR, and use Random Search (RS) as a baseline for comparison. We use 84 OCL constraints from four case studies belonging to different domains with varying size and complexity. The experimental results show that our proposed strategy of reusing already generated test data is better as compared to generating test data without using previous test data.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Similar content being viewed by others
References
Aichernig, B.K., Salas, P.A.P.: Test case generation by OCL mutation and constraint solving. In: Fifth International Conference on Quality Software (QSIC 2005), pp. 64–71. IEEE (2005)
Ali, S., Iqbal, M.Z., Khalid, M., Arcuri, A.: Improving the performance of OCL constraint solving with novel heuristics for logical operations: a search-based approach. Empir. Softw. Eng. 21(6), 2459–2502 (2016)
Ali, S., Iqbal, M.Z., Arcuri, A., Briand, L.C.: Generating test data from ocl constraints with search techniques. IEEE Trans. Softw. Eng. 39(10), 1376–1402 (2013)
Ali, S., Yue, T., Zohaib Iqbal, M., Panesar-Walawege, R.K.: Insights on the use of OCL in diverse industrial applications. In: Amyot, D., Fonseca i Casas, P., Mussbacher, G. (eds.) SAM 2014. LNCS, vol. 8769, pp. 223–238. Springer, Cham (2014). https://doi.org/10.1007/978-3-319-11743-0_16
Ali, S., Yue, T., Qiu, X., Lu, H.: Generating boundary values from OCL constraints using constraints rewriting and search algorithms. In: 2016 IEEE Congress on Evolutionary Computation (CEC), pp. 379–386. IEEE (2016)
Arcuri, A., Briand, L.: A practical guide for using statistical tests to assess randomized algorithms in software engineering. In: 2011 33rd International Conference on Software Engineering (ICSE), pp. 1–10. IEEE (2011)
Awedikian, Zeina, K.A., Antoniol, G.: MC/DC automatic test input data generation. In: Proceedings of the 11th Annual Conference on Genetic and Evolutionary Computation, pp. 1657–1664. ACM (2009)
Benattou, M., Bruel, J.M., Hameurlain, N.: Generating test data from OCL specification. In: Proceedings of ECOOP Workshop Integration and Transformation of UML Models (2002)
Cabot, J.: OCL repository (2014). https://github.com/jcabot/ocl-repository
Chilenski, J.J., Miller, S.P.: Applicability of modified condition/decision coverage to software testing. Softw. Eng. J. 9(5), 193–200 (1994)
Ferrell, T., Ferrell, U.: RTCA DO-178C/EUROCAE ED-12C (2017)
Frias, L., Queralt Calafat, A., Olivé Ramon, A.: EU-rent car rentals specification (2003). http://hdl.handle.net/2117/97816
Ghani, K., Clark, J.A.: Automatic test data generation for multiple condition and MCDC coverage. In: Fourth International Conference on Software Engineering Advances, ICSEA 2009, pp. 152–157. IEEE (2009)
Godboley, S., Prashanth, G., Mohapatro, D.P., Majhi, B.: Increase in modified condition/decision coverage using program code transformer. In: 2013 IEEE 3rd International Advance Computing Conference (IACC), pp. 1400–1407. IEEE (2013)
Gupta, N., Mathur, A.P., Soffa, M.L.: Automated test data generation using an iterative relaxation method. ACM SIGSOFT Softw. Eng. Notes 23(6), 231–244 (1998)
Gupta, N., Mathur, A.P., Soffa, M.L.: Generating test data for branch coverage. In: Proceedings of the Fifteenth IEEE International Conference on Automated Software Engineering, ASE 2000, pp. 219–227. IEEE (2000)
Hemmati, H., Arefin, S.S., Loewen, H.W.: Evaluating specification-level MC/DC criterion in model-based testing of safety critical systems. In: 2018 IEEE/ACM 40th International Conference on Software Engineering: Software Engineering in Practice Track (ICSE-SEIP), pp. 256–265. IEEE (2018)
Lakhotia, K., Harman, M., McMinn, P.: A multi-objective approach to search-based test data generation. In: Proceedings of the 9th Annual Conference on Genetic and Evolutionary Computation, pp. 1098–1105. ACM (2007)
Leake, D.: Case-Based Reasoning: Experiences. Lessons and Future Directions. MIT Press, Cambridge (1996)
Li, D., Hu, L., Gao, R., Wong, W.E., Kuhn, D.R., Kacker, R.N.: Improving MC/DC and fault detection strength using combinatorial testing. In: 2017 IEEE International Conference on Software Quality, Reliability and Security Companion (QRS-C), pp. 297–303. IEEE (2017)
Offutt, J., Liu, S., Abdurazik, A., Ammann, P.: Generating test data from state-based specifications. Softw. Test. Verif. Reliab. 13(1), 25–53 (2003)
OMG: Object constraint language specification v2.4. Object Management Group Inc. (2014). http://www.omg.org/spec/OCL/2.4/
OMG: UML. unified modeling language specification, version 2.5.1. Object Management Group Inc. (2017). http://www.omg.org/spec/UML/2.5.1/
Packevicius, S., Krivickaite, G., Barisas, D., Jasaitis, R., Blazauskas, T., Guogis, E.: Test data generation for complex data types using imprecise model constraints and constraint solving techniques. Inf. Technol. Control. 42(2), 131–149 (2013)
Panichella, A., Kifetew, F.M., Tonella, P.: Automated test case generation as a many-objective optimisation problem with dynamic selection of the targets. IEEE Trans. Softw. Eng. 44(2), 122–158 (2018)
Rajan, A., Whalen, M.W., Heimdahl, M.P.: The effect of program and model structure on MC/DC test adequacy coverage. In: Proceedings of the 30th International Conference on Software Engineering, pp. 161–170. ACM (2008)
Rojas, J.M., Vivanti, M., Arcuri, A., Fraser, G.: A detailed investigation of the effectiveness of whole test suite generation. Empir. Softw. Eng. 22(2), 852–893 (2017)
Spitzer, C., Ferrell, U., Ferrell, T.: Digital Avionics Handbook. CRC Press, Boca Raton (2014)
Utting, M., Legeard, B.: Practical Model-Based Testing: A Tools Approach. Elsevier, Amsterdam (2010)
Vargha, A., Delaney, H.D.: A critique and improvement of the CL common language effect size statistics of McGraw and wong. J. Educ. Behav. Stat. 25(2), 101–132 (2000)
Warmer, J.B., Kleppe, A.G.: The Object Constraint Language: Getting Your Models Ready for MDA. Addison-Wesley Professional, Boston (2003)
Weyuker, E., Goradia, T., Singh, A.: Automatically generating test data from a boolean specification. IEEE Trans. Softw. Eng. 20(5), 353–363 (1994)
Woodward, M.R., Hennell, M.A.: On the relationship between two control-flow coverage criteria: all JJ-paths and MCDC. Inf. Softw. Technol. 48(7), 433–440 (2006)
Yu, Y.T., Lau, M.F.: A comparison of MC/DC, mumcut and several other coverage criteria for logical decisions. J. Syst. Softw. 79(5), 577–590 (2006)
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2019 Springer Nature Switzerland AG
About this paper
Cite this paper
Sartaj, H., Iqbal, M.Z., Jilani, A.A.A., Khan, M.U. (2019). A Search-Based Approach to Generate MC/DC Test Data for OCL Constraints. In: Nejati, S., Gay, G. (eds) Search-Based Software Engineering. SSBSE 2019. Lecture Notes in Computer Science(), vol 11664. Springer, Cham. https://doi.org/10.1007/978-3-030-27455-9_8
Download citation
DOI: https://doi.org/10.1007/978-3-030-27455-9_8
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-030-27454-2
Online ISBN: 978-3-030-27455-9
eBook Packages: Computer ScienceComputer Science (R0)