Table 4: Def/Use table for the Observer pattern. Bullet items indicate test covered def-use pairs.
class:
Subject
DEF
var:
observers
level: 0 attach(Observer*) detach(Observer*) Subject()
∼Subject() •
USE attach(Observer*) •
detach(Observer*) •
notify() •
are supposed to document the relevant attributes of
salient classes which are most critical for inter-class
interaction (Cockburn, 1996). This can be done as
an annotation of UML class diagrams comprising the
specification or the implementation model (Fowler,
2003). In the testing stage, Def/Use tables are au-
tomatically derived through source code analysis, and
code is automatically instrumented using Aspect Ori-
ented Programming. The application is then tested
on a suite of cases selected according to any specific
approach (e.g. derived from use cases (Heumann,
2001)), and their execution is logged to a file con-
taining the trace of the methods effectively exercised.
Coverage analysis is finally performed through offline
check of the def-use paths reported in the log file and
contained in the tables.
REFERENCES
Baudry, B. and Traon, Y. L. (2005). Measuring design testa-
bility of a uml class diagram. Information and Soft-
ware Technology, 1(47).
Beizer, B. (1990). Software testing techniques (2nd ed.).
Van Nostrand Reinhold Co., New York, NY, USA.
Binder, R. V. (1994). Design for testability in object-
oriented systems. Commun. ACM, 37(9):87–101.
Chen, Y., Qiu, W., Zhou, B., and Peng, C. (2004). An
automatic test coverage analysis for systemc descrip-
tion using aspect-oriented programming. In Computer
Supported Cooperative Work in Design. Proceedings.
The 8th International Conference on, Vol. 2, pages 632
– 636.
Cockburn, A. (1996). The interaction of social issues and
software architecture. Commun. ACM, 39(10):40–46.
Fowler, M. (2003). UML Distilled: A Brief Guide to
the Standard Object Modeling Language. Addison-
Wesley Longman Publishing Co., Inc., Boston, MA,
USA.
Fujiwara, S., von Bochmann, G., Khendek, F., Amalou, M.,
and Ghedamsi, A. (1991). Test selection based on fi-
nite state models. IEEE Trans. Softw. Eng., 17(6):591–
603.
Gallagher, L., Offutt, J., and Cincotta, A. (2006). Integra-
tion testing of object-oriented components using finite
state machines: Research articles. Softw. Test. Verif.
Reliab., 16(4):215–266.
Gamma, E., Helm, R., Johnson, R., and Vlissides, J. (1995).
Design patterns: elements of reusable object-oriented
software. Addison-Wesley Longman Publishing Co.,
Inc., Boston, MA, USA.
Harrold, M. J. and Rothermel, G. (1994). Performing data
flow testing on classes. In SIGSOFT ’94: Proceedings
of the 2nd ACM SIGSOFT symposium on Foundations
of software engineering, pages 154–163. ACM Press.
Heumann, J. (2001). Generating test cases from use cases.
The Rational Edge. Retrieved January 20, 2007, from
www.therationaledge.com.
Holley, L. H. and Rosen, B. K. (1981). Qualified data flow
problems. IEEE Trans. Softw. Eng., 7(1):60–78.
Hong, H. S., Kwon, Y. R., and Cha, S. D. (1995). Test-
ing of object-oriented programs based on finite state
machines. In APSEC ’95: Proceedings of the Second
Asia Pacific Software Engineering Conference, page
234. IEEE Computer Society.
Kiczales, G., Lamping, J., Mendhekar, A., Maeda, C.,
Lopes, C. V., Loingtier, J.-M., and Irwin, J. (1997).
Aspect-oriented programming. In Proceedings of the
11th European Conference on Object-Oriented Pro-
gramming, pages 220–242.
Kuhn, T. and Thomann, O. (2006). Abstract syntax tree.
Eclipse Corner Articles. Retrieved October 23, 2006,
from http://www.eclipse.org/articles/index.php.
Ntafos, S. C. (1988). A comparison of some structural test-
ing strategies. IEEE Trans. Softw. Eng., 14(6):868–
874.
Pande, H. D. and Landi, W. (1991). Interprocedural def-use
associations in c programs. In TAV4: Proceedings of
the symposium on Testing, analysis, and verification,
pages 139–153, New York, NY, USA. ACM Press.
Rajan, H. and Sullivan, K. (2005). Aspect language fea-
tures for concern coverage profiling. In AOSD ’05:
Proceedings of the 4th international conference on
Aspect-oriented software development, pages 181–
191. ACM Press.
Rapps, S. and Weyuker, E. J. (1985). Selecting software test
data using data flow information. IEEE Trans. Softw.
Eng., 11(4):367–375.
Yannakakis, M. and Lee, D. (1995). Testing finite state
machines: fault detection. In Selected papers of the
23rd annual ACM symposium on Theory of comput-
ing, pages 209–227. Academic Press, Inc.
ICSOFT 2007 - International Conference on Software and Data Technologies
60