UML Associations - Reducing the Gap in Test Coverage between Model and Code

Anders Eriksson, Birgitta Lindström


This paper addresses the overall problem of estimating the quality of a test suite when testing is performed at a platform-independent level, using executable UML models. The problem is that the test suite is often required to fulfill structural code coverage criteria. In the avionics domain it is usually required that the tests achieve 100% coverage according to logic-based coverage criteria. Such criteria are less effective when applied to executable UML models than when they are applied to code because the action code found in such models contains conditions in navigation and loops that are not explicit and therefore not captured by logic-based coverage criteria. We present two new coverage criteria for executable UML models, and we use an industrial application from the avionics domain to show that these two criteria should be combined with a logic-based criterion when testing the executable UML model. As long as the coverage is less than 100% at the model level, there is no point in running the tests at the code level since all functionality of the model is not yet tested, and this is necessary to achieve 100% coverage at the code level.


  1. Akehurst, D., Howells, G., and McDonald-Maier, K. (2007). Implementing associations: Uml 2.0 to java 5. Software & Systems Modeling, 6(1):3-35.
  2. Ammann, P. and Offutt, J. (2008). Introduction to software testing. New York: Cambridge University Press, ISBN 978-0-521-88038-1.
  3. Andrews, A., France, R., Ghosh, S., and Craig, G. (2003). Test adequacy criteria for UML design models. Software Testing, Verification and Reliability , 13(2):95- 127.
  4. Binder, R. (2000). Testing object-oriented systems: models, patterns, and tools. Addison-Wesley Professional.
  5. Chen, P. P.-S. (1976). The entity-relationship modeltoward a unified view of data. ACM Transactions on Database Systems (TODS), 1(1):9-36.
  6. Chilenski, J. J. (2001). An investigation of three forms of the modified condition decision coverage (MCDC) criterion. Technical report, Office of Aviation Research.
  7. Chow, T. S. (1978). Testing software design modeled by finite-state machines. IEEE Trans. Software Eng., 4(3):178-187.
  8. Diskin, Z., Easterbrook, S. M., and Dingel, J. (2008). Engineering Associations: From Models to Code and Back through Semantics. In TOOLS (46), pages 336-355. Springer.
  9. Eriksson, A., Lindstr öm, B., Andler, S. F., and Offutt, J. (2012). Model Transformation Impact on Test Artifacts: An Empirical Study. In Proceedings of the 9th workshop on Model-Driven Engineering, Verification and Validation.
  10. Eriksson, A., Lindström, B., and Offutt, J. (2013). Transformation rules for platform independent testing: An empirical study. In Software Testing, Verification and Validation (ICST), 2013 IEEE Sixth International Conference on, pages 202-211.
  11. Goldberg, M. and Wiener, G. (2011). Generating Code for Associations Supporting Operations on Multiple Instances. In Evaluation of Novel Approaches to Software Engineering, pages 163-177. Springer.
  12. Hayhurst, K. J. and Veerhusen, D. S. (2001). A practical approach to modified condition/decision coverage. In Digital Avionics Systems, 2001. DASC. 20th Conference, volume 1, pages 1B2-1. IEEE.
  13. Howden, W. E. (1978). An evaluation of the effectiveness of symbolic testing. Software: Practice and Experience, 8(4):381-397.
  14. Hutchinson, J., Whittle, J., Rouncefield, M., and Kristoffersen, S. (2011). Empirical assessment of mde in industry. In Proceedings of the 33rd International Conference on Software Engineering, pages 471-480. ACM.
  15. Kirner, R. (2009). Towards preserving model coverage and structural code coverage. EURASIP Journal on Embedded Systems, 2009:6:1-6:16.
  16. Mellor, S. J. and Balcer, M. J. (2002). Executable UML: A Foundation for Model Driven Architecture. Boston: Addison Wesley, ISBN 0-201-74804-5.
  17. Mellor, S. J., Scott, K., Uhl, A., and Weise, D. (2004). MDA Distilled: Priciples of Model-Driven Architecture. Boston: Addison Wesley, ISBN 0-201-78891-8.
  18. Milicev, D. (2007). On the semantics of associations and association ends in uml. Software Engineering, IEEE Transactions on, 33(4):238-251.
  19. Nelson, S., Noble, J., and Pearce, D. J. (2008). Implementing first-class relationships in Java. Proceedings of RAOOL, 8.
  20. OMG (2011). Unified Modeling Language (UML), Superstructure, version 2.4.1. http://
  21. OMG (2013). Action Lanaguage for Foundational UML (ALF), version 1.0.1. retrived September 14, 2011.
  22. OMG (2013). Foundational Subset of Executable UML (FUML), version 1.1.
  23. Planas, E., Cabot, J., and Gmez, C. (2009). Verifying Action Semantics Specifications in UML Behavioral Models. In Advanced Information Systems Engineering, volume 5565 of LNCS, pages 125-140. Springer Berlin / Heidelberg.
  24. RTCA (2011a). RTCA Inc. DO-1'C: Software Considerations in Airborne Systems and Equipment Certification.
  25. RTCA (2011b). RTCA Inc. DO-331: Model-Based Development and Verification Supplement to DO-1'C and DO-2'A.
  26. Rumbaugh, J. (1987). Relations as semantic constructs in an object-oriented language. In ACM Sigplan Notices, volume 22, pages 466-481. ACM.
  27. Selic, B. (2012). The Less Well Known UML. In Formal Methods for Model-Driven Engineering, pages 1-20. Springer.
  28. White, L. J. and Wiszniewski, B. (1991). Path testing of computer programs with loops using a tool for simple loop patterns. Softw. Pract. Exper., 21(10):1075- 1102.
  29. Zhu, H., Hall, P. A., and May, J. H. (1997). Software unit test coverage and adequacy. Acm computing surveys (csur), 29(4):366-427.

Paper Citation

in Harvard Style

Eriksson A. and Lindström B. (2016). UML Associations - Reducing the Gap in Test Coverage between Model and Code . In Proceedings of the 4th International Conference on Model-Driven Engineering and Software Development - Volume 1: MODELSWARD, ISBN 978-989-758-168-7, pages 589-599. DOI: 10.5220/0005745205890599

in Bibtex Style

author={Anders Eriksson and Birgitta Lindström},
title={UML Associations - Reducing the Gap in Test Coverage between Model and Code},
booktitle={Proceedings of the 4th International Conference on Model-Driven Engineering and Software Development - Volume 1: MODELSWARD,},

in EndNote Style

JO - Proceedings of the 4th International Conference on Model-Driven Engineering and Software Development - Volume 1: MODELSWARD,
TI - UML Associations - Reducing the Gap in Test Coverage between Model and Code
SN - 978-989-758-168-7
AU - Eriksson A.
AU - Lindström B.
PY - 2016
SP - 589
EP - 599
DO - 10.5220/0005745205890599