Skip to main content

An Approach to Testing Java Implementation against Its UML Class Model

  • Conference paper
Book cover Model-Driven Engineering Languages and Systems (MODELS 2013)

Part of the book series: Lecture Notes in Computer Science ((LNPSE,volume 8107))

Abstract

Model Driven Engineering (MDE) aims to expedite the software development process by providing support for transforming models to running systems. Many modeling tools provide forward engineering features that automatically translate a model into a skeletal program that developers must complete. Inconsistencies between a design model and its implementation can result as a consequence of manually-added code. Manually checking that an implementation conforms to the model is a daunting task. Thus, there is a need for MDE tools that developers can use to check whether an implementation conforms to a model, especially when generated code is manually modified. This paper presents an approach for testing that an implementation satisfies the constraints specified in its design model. We also describe a prototypical tool that supports the approach, and we describe how its application to two Eclipse UML2 projects uncovered errors.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Systems, R.: Software Testing and Validation with Reactis (2013), http://www.reactive-systems.com/ (accessed June 7, 2013)

  2. Omg: OMG Unified Modeling Language (OMG UML), Superstructure Specification (Version 2.4.1). Tech. rep., Object Management Group (2011), http://www.omg.org/spec/UML/2.4.1/ (accessed June 7, 2013)

  3. Omg: OMG Object Constraint Language (OCL) Version 2.3.1. Tech. rep (2012), http://www.omg.org/spec/OCL/2.3.1/ (accessed June 7, 2013)

  4. IBM: IBM Rational Software and Systems Delivery (2013), http://www-01.ibm.com/software/rational/ (accessed June 7, 2013)

  5. Warmer, J., Kleppe, A.: The Object Constraint Language: Getting Your Models Ready for MDA, 2nd edn. Addison-Wesley Longman Publishing Co., Inc., Boston (2003)

    Google Scholar 

  6. Kannan, Y., Sen, K.: Universal Symbolic Execution and its Application to Likely Data Structure Invariant Generation. In: Proceedings of the 2008 International Symposium on Software Testing and Analysis, New York, NY, USA, pp. 283–294 (2008)

    Google Scholar 

  7. Ammann, P., Offutt, J.: Introduction to Software Testing, 1st edn. Cambridge University Press, New York (2008)

    Book  MATH  Google Scholar 

  8. Foundation, T.: Eclipse Modeling - MDT - Home (2013), http://www.eclipse.org/modeling/mdt/ (accessed June 7, 2013)

  9. Foundation, T.: Eclipse Modeling - MDT - OCL (2013), http://www.eclipse.org/modeling/mdt/downloads/?project=ocl (accessed June 7, 2013)

  10. Consortium, O.: ASM Home Page (2013), http://asm.ow2.org/ (accessed June 7, 2013)

  11. Le Berre, D., Parrain, A.: The Sat4j Library, Release 2.2. Journal on Satisfiability, Boolean Modeling and Computation 7, 59–64 (2010)

    Google Scholar 

  12. Barbier, F., Henderson-Sellers, B., Le Parc-Lacayrelle, A., Bruel, J.-M.: Formalization of the Whole-Part Relationship in the Unified Modeling Language. IEEE Trans. Softw. Eng. 29(5), 459–470 (2003)

    Article  Google Scholar 

  13. Boyapati, C., Liskov, B., Shrira, L.: Ownership Types for Object Encapsulation. In: Proceedings of the 30th ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, New York, NY, USA, pp. 213–223 (2003)

    Google Scholar 

  14. Guhneuc, Y.-G., Albin-Amiot, H.: Recovering Binary Class Relationships: Putting Icing on the UML Cake. In: Proceedings of the 19th Annual ACM SIGPLAN Conference on Object-oriented Programming, Systems, Languages, and Applications, New York, NY, USA, pp. 301–314 (2004)

    Google Scholar 

  15. Darga, P., Boyapati, C.: Efficient Software Model Checking of Data Structure Properties. In: Proceedings of the 21st Annual ACM SIGPLAN Conference on Object-oriented Programming Systems, Languages, and Applications, New York, NY, USA, pp. 363–382 (2006)

    Google Scholar 

  16. Boyapati, C., Khurshid, S., Marinov, D.: Korat: Automated Testing Based on Java Predicates. In: Proceedings of the 2002 ACM SIGSOFT International Symposium on Software Testing and Analysis, New York, NY, USA, pp. 123–133 (2002)

    Google Scholar 

  17. Abdurazik, A., Offutt, J.: Using UML Collaboration Diagrams for Static Checking and Test Generation. In: Proceedings of the 3rd International Conference on The Unified Modeling Language: Advancing the Standard, Berlin, Heidelberg, pp. 383–395 (2000)

    Google Scholar 

  18. Roychoudhury, A., Goel, A., Sengupta, B.: Symbolic Message Sequence Charts. ACM Trans. Softw. Eng. Methodol. 12, 12:1–12:44 (2012)

    Google Scholar 

  19. Akehurst, D., Howells, G., McDonald-Maier, K.: Implementing associations: UML 2.0 to Java 5. 0 to Java 5. Software & Systems Modeling 6(1), 3–35 (2007)

    Article  Google Scholar 

  20. Milanova, A.: Precise Identification of Composition Relationships for UML Class Diagrams. In: Proceedings of the 20th IEEE/ACM International Conference on Automated Software Engineering, New York, NY, USA, pp. 76–85 (2005)

    Google Scholar 

  21. KeY Project: Integrated Deductive Software Design (2013), http://www.key-project.org/ (accessed June 7, 2013)

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2013 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Chavez, H.M., Shen, W., France, R.B., Mechling, B.A. (2013). An Approach to Testing Java Implementation against Its UML Class Model. In: Moreira, A., Schätz, B., Gray, J., Vallecillo, A., Clarke, P. (eds) Model-Driven Engineering Languages and Systems. MODELS 2013. Lecture Notes in Computer Science, vol 8107. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-41533-3_14

Download citation

  • DOI: https://doi.org/10.1007/978-3-642-41533-3_14

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-642-41532-6

  • Online ISBN: 978-3-642-41533-3

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics