skip to main content
10.1145/1119655.1119680acmotherconferencesArticle/Chapter ViewAbstractPublication PagesmodularityConference Proceedingsconference-collections
Article

State-based incremental testing of aspect-oriented programs

Published: 20 March 2006 Publication History

Abstract

Taking aspects as incremental modifications to their base classes, this paper presents an incremental approach to testing whether or not aspect-oriented programs and their base classes conform to their respective behavior models. We exploit a rigorous aspect-oriented extension to state models for capturing the impact of aspects on the state transitions of base class objects as well as an explicit weaving mechanism for composing aspects into their base models. We generate abstract tests for base classes and aspect-oriented programs from their state models. As base class tests are not necessarily valid for aspect-oriented programs, we identify several rules for maximizing reuse of concrete base class tests for aspects according to the state-based impact of aspects on their base classes. To illustrate our approach, we use two examples that indicate distinctive types of aspect-oriented applications and exhibit fundamental features in complex applications: aspects removing state transitions from base classes and aspects adding and modifying state transitions in base classes. Our results show that majority of base class tests can be reused for aspects, but subtle modifications to some of them are necessary. In particular, positive (or negative) base class tests can become negative (or positive) aspect tests. We also discuss how several types of aspect-specific faults can be revealed by the state-based testing.

References

[1]
Aldawud, O., Bader, F., and Elrad, T. Weaving with Statecharts. The Second International Workshop on Aspect Oriented Modeling. 2002.
[2]
Aldawud, T. and Bader, A. UML profile for aspect-oriented software development, The Third International Workshop on Aspect Oriented Modeling, 2003.
[3]
Alexander, R. T., Bieman, J. M., and Andrews, A. A. Towards the systematic testing of aspect-oriented programs, Technical Report, Colorado State University. http://www.cs.colostate.edu/~rta/publications/CS-04-105.pdf.
[4]
Binder, R. V. Testing Object-Oriented Systems: Models, Patterns, and Tools. Addison-Wesley, 2000.
[5]
Blackburn, M, Busser, R., Nauman, A., Knickerbocker, R., and Kasuda, R. Mars Polar Lander fault identification using model-based testing. In Proc. of the Eighth International Conference on Engineering of Complex Computer Systems, 2002.
[6]
Chavez, C. and Lucena, C. A Metamodel for aspect-oriented modeling, The Workshop on Aspect-Oriented Modeling with UML, 2002.
[7]
Coelho, W. and Murphy, G. C. ActiveAspect: Presenting crosscutting structure. ICSE First International Workshop on the Modeling and Analysis of Concerns in Software. 2005.
[8]
Dalal, S. R., Jain, A., Karunanithi, N., Leaton, J. M., Lott, C. M., Patton, G. C., and Horowitz, B. M. Model-based testing in practice. In Proc. of the 21st International Conf. on Software Engineering (ICSE'99), 1999.
[9]
El-Far, I. K. and Whittaker, J. A. Model-based software testing. In Encyclopedia on Software Engineering (edited by Marciniak), Wiley, 2001.
[10]
Elrad, T., Aldawud, O., and Bader, A. Expressing aspects using UML behavior and structural diagrams. In Aspect-Oriented Software Development (edited by Filman, R. E. et al.). Addison-Wesley, 2005.
[11]
Gradecki, J. and Lesiecki, N. Mastering AspectJ: Aspect-Oriented Programming in Java. Wiley, 2003.
[12]
Groher, I. and Schulze, S. Generating aspect code from UML models. The Third International Workshop on Aspect-Oriented Modeling. 2003.
[13]
Han, Y., Kniesel, G., and Cremers, A. B. A meta model and modeling notation for AspectJ, The 5th AOSD Modeling with UML Workshop, 2004.
[14]
Kiczales, G., Hilsdale, E., Hugunin, J., Kersten, M., Palm, J. and Griswold, W. G., An overview of AspectJ. In Proc. of ECOOP'01, pp. 327--353, 2001.
[15]
Kiczales, G., Lamping, J., Mendhekar, A., Maeda, C., Lopes, C. V., Loingtier, J. M. and Irwin, J., Aspect-oriented programming. In Proc. of ECOOP'97, LNCS 1241, pp. 220--242, 1997.
[16]
McEachen, N. and Alexander, R. T. Distributing classes with woven concerns: an exploration of potential fault scenario. In Proc. of the Fourth International Conference on Aspect-Oriented Software Development (AOSD'05). pp. 192--200, 2005.
[17]
Mellor, S. J. A framework for aspect-oriented modeling. The 4th AOSD Modeling With UML Workshop, 2003.
[18]
Meyer, B. Object-Oriented Software Construction. Englewood Cliffs, N.J.: Prentice-Hall, 1988.
[19]
Orleans, D. Incremental programming with extensible decisions, In Proceedings of the 1st International Conference on Aspect-Oriented Software Development, April 2002, The Netherlands.
[20]
Prenninger, W. and Pretschner, A. Abstractions for model-based testing. In Proc. of the 2nd Intl. Workshop on Test and Analysis of Component Based Systems (TACoS'04), Electronic Notes in Theoretical Computer Science 116:59--71, 2005.
[21]
Pretschner, A., Prenninger, W., Wagner, S., Kühnel, C., Baumgartner, M., Sostawa, B., Zölch, R., and Stauner, T. One evaluation of model-based testing and its automation. In Proc. of the 27th International Conf. on Software Engineering (ICSE'05), 2005.
[22]
Pretschner, A., Slotosch, O., Aiglstorfer, E., and Kriebel, S. Model-based testing for real - The inhouse card case study. J. Software Tools for Technology Transfer 5(2-3):140--157, 2004.
[23]
Ray, I., France, R., Li, N., and Georg, G. An aspect-based approach to modeling access control concerns. Information and Software Technology, vol. 46, no.9, pp. 575--587, 2004.
[24]
Stein, D., Hanenberg, S., and Unland, R. An UML-based aspect-oriented design notation for AspectJ. In Proceedings of the First International Conference on Aspect-Oriented Software Development, pp. 106--112. ACM Press, 2002.
[25]
Tkatchenko, M. and Kiczales, G. Uniform support for modeling crosscutting structure. The 6th International Workshop on Aspect-Oriented Modeling (AOM'05). 2005.
[26]
Xie, T., Zhao, J., Marinov, D., and Notkin, D. Automated test generation for AspectJ programs, AOSD 2005 Workshop on Testing Aspect-Oriented Programs, Chicago, 2005.
[27]
Xu, D. Test generation from aspect-oriented state models. Technical Report, NDSU-CS-TR-XU02, North Dakota State University Department of Computer Science, Sept. 2005.
[28]
Xu, D., Xu, W., and Nygard, K. A state-based approach to testing aspect-oriented programs. In Proc. of the 17th International Conference on Software Engineering and Knowledge Engineering (SEKE'05), July 14--16, Taiwan.
[29]
Xu, W. and Xu, D. A model-based approach to test generation for aspect-oriented programs. AOSD 2005 Workshop on Testing Aspect-Oriented Programs, Chicago, March 2005.
[30]
Zhao, J. and Rinard, M., System dependence graph construction for aspect-oriented programs, MIT-LCS-TR-891, Laboratory for Computer Science, MIT, 2003.
[31]
Zhao, J. Data-flow-based unit testing of aspect-oriented programs, In Proc of the 27th Annual IEEE International Computer Software and Applications Conference (COMPSAC'03), pp. 188--197, 2003.
[32]
Zhou, Y., Richardson, D., and Ziv, H. Towards a practical approach to test aspect-oriented software. In Proc. the 2004 Workshop on Testing Component-Based Systems (TECOS), Sept. 2004.

Cited By

View all

Recommendations

Comments

Information & Contributors

Information

Published In

cover image ACM Other conferences
AOSD '06: Proceedings of the 5th international conference on Aspect-oriented software development
March 2006
247 pages
ISBN:159593300X
DOI:10.1145/1119655
Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

Sponsors

  • AOSD-Europe: European Network of Excellent on Aspect-oriented Software Development

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 20 March 2006

Permissions

Request permissions for this article.

Check for updates

Author Tags

  1. aspect-oriented programming
  2. aspect-oriented state model
  3. incremental testing
  4. model-based testing
  5. state model

Qualifiers

  • Article

Conference

AOSD06
Sponsor:
  • AOSD-Europe

Acceptance Rates

Overall Acceptance Rate 41 of 139 submissions, 29%

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)1
  • Downloads (Last 6 weeks)0
Reflects downloads up to 24 Dec 2024

Other Metrics

Citations

Cited By

View all

View Options

Login options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

Media

Figures

Other

Tables

Share

Share

Share this Publication link

Share on social media