Skip to main content
Log in

Observability using aspect-oriented programming for OO software testing

  • Original Article
  • Published:
International Journal of System Assurance Engineering and Management Aims and scope Submit manuscript

Abstract

Software testing is a process of executing software with the goal of finding errors. It is an important phase in the software development process. It still remains an art due to limitations in understanding of the principles of software. In this paper, we present a new approach to testing object-oriented software using aspect-oriented programming. We propose an aspect-based testing technique that facilitates observing internal details of execution at unit, integration and system levels, during testing of object-oriented software. Our technique adapts logging aspect, to suit the testing needs of object-oriented software. The logging aspect is introduced externally to the software under test, for observing the system’s internal and external behavior. The internal execution details are stored in a log file for use during post-analysis. Test coverage reports are generated from the information gathered from the log file. It includes coverage at method, class, inheritance and dynamic binding levels.

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

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6
Fig. 7
Fig. 8
Fig. 9
Fig. 10
Fig. 11

Similar content being viewed by others

References

  • Afonso F, Silva C, Montenegro S, Tavares A (2007) Applying aspects to a real-time embedded operating system. In: Proceedings of 6th workshop on aspects, components, and patterns for infrastructure software ACP4IS’07. Vancouver, British Columbia, Canada

  • AspectJ (2010) AspectJ 1.6.9 is available on http://www.eclipse.org/aspectj/. Accessed June 2010

  • Bodden E, Havelund K, (2008) Racer: effective race detection using AspectJ. In: ISSTA, ACM Press, Seattle, pp 155–165

  • Briand LC, Labiche Y, Leduc J (2005) Tracing distributed system executions using AspectJ. In: Proceeding of 21st IEEE international conference on software maintenance, IEEE Computer Society Press, Los Alamitos, pp 81–90

  • Bruel J, Araújo J, Moreira A, Royer A (2003) Using aspects to develop built-in tests for components. In: Proceeding to UML 2003 workshop on aspect oriented modeling with UML. UML, San Francisco, USA

  • Bruno H, John R, Gurd (2004) Using AspectJ to separate concerns in parallel scientific Java code. In: Proceedings of 3rd international conference on AOSD. ACM Press, New York, pp 122–131

  • Cheon Y, Avila C (2010) Automating Java program testing using OCL and AspectJ. In: Shahram Latifi (ed) 7th International conference on information technology: new generations, Las Vegas, 12–14 April, 2010. IEEE Computer Society, Las Vegas, pp 1020–1025

  • Goel A, Gupta SC, Wasan SK (2003) Probe mechanism for object-oriented software testing. In: Proceedings of fundamental approaches to software engineering (FASE), Springer, Poland, LNCS 2621: 310–324

  • Gschwind T, Oberleitner J (2003) Improving dynamic data analysis with aspect-oriented programming. In: Proceeding of 7th European conference on software maintenance and reengineering (CSMR), IEEE Computer Society, Los Alamitos, pp 91–100

  • Harrold MJ, Jones J, Li T, Liang D, Orso A, Pennings M, Sinha S, Spoon SA, Gujarathi A (2001) Regression test selection for Java software. In: Conference object-oriented programming systems, languages and applications, ACM, New York, pp 312–326

  • Hilsdale E, Hugunin J (2004) Advice weaving in AspectJ. In: Proceedings 3rd international conference on aspect-oriented software development, ACM Press, New York, pp 26–35

  • Kiczales G, Lamping J, Mendhekar A, Maeda A, Maeda C, Lopes CV, Loingtier JM, Irwin J (1997) Aspect-oriented programming. In: Proceeding of 11th European conference on object-oriented programming (ECOOP’97), Springer-Verlag, Berlin, LNCS 1241:220–242

  • Kiczales G, Hilsdale E, Hugunin J, Kersten M, Palm J, Griswold WG (2001a) An overview of AspectJ. In: Knudsen JL (ed.) Proceedings ECOOP, Springer-Verlag LNCS, Berlin, 2072: 327–353

  • Kiczales G, Hilsdale E, Hugunin J, Kersten M, Palm J, Griswold WG (2001b) Getting started with AspectJ. Comm ACM 44(10):59–65

    Article  Google Scholar 

  • Laddad R (2009) AspectJ in action: practical aspect oriented programming, second edition. Manning Publication, Greenwich, USA

    Google Scholar 

  • Lee S (2006) Modifying reflexion model with ASpectJ. Final Report for CPSC 511 at UBC, Columbia

  • Lippert M, Lopes CV (2000) A study on exception detection and handling using aspect oriented programming. In: Proceedings of the 22nd ICSE, ACM, Limerick, pp 418–427

  • Li X, Xusheng X (2009) Research of software testing based on AOP. In: Proceedings of 3rd international symposium on intelligent information technology application (IITA). IEEE Computer Society, Nanchang, China, pp 187–189

  • Meetei MZ, Goel A, Wasan SK (2009) An overview of Logging with aspect oriented programming. Accepted for publication in WCSE. IEEE Computer Society Press, Xiamen, China

    Google Scholar 

  • Moa C (2007) AOP-based testability improvement for component–based software. In: 31st Annual international computer software and applications conference, IEEE Computer Society Press, Beijing, pp 547–552

  • Sokenou D, Vösgen M (2005) FlexTest: An aspect-oriented framework for unit testing. In: 2nd International workshop on software quality (SOQUA), Net.ObjectDays, Erfurt

  • Störzer M, Krinke J, Breu S (2003) Trace Analysis for Aspect Application. IPro of workshop on analysis of aspect-oriented software (AAOS), Darmstadt, Germany

  • Sun Microsystems (2010) Java 2 platform standard edition v 1.4.2 API specification. Available at http://download.oracle.com/javase/1.4.2/docs/api/

  • Xie T, Zhao J (2006) A Framework and tool supports for generating test inputs of aspectj programs. In: Proceedings 5th International conference on aspect-oriented software development, Bonn, Germany, pp 190–201

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Mutum Zico Meetei.

Rights and permissions

Reprints and permissions

About this article

Cite this article

Meetei, M.Z., Goel, A. & Wasan, S.K. Observability using aspect-oriented programming for OO software testing. Int J Syst Assur Eng Manag 2, 85–96 (2011). https://doi.org/10.1007/s13198-011-0066-5

Download citation

  • Received:

  • Revised:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s13198-011-0066-5

Keywords

Navigation