Conformance Testing of Object-Oriented Components Specified by State/Transition Classes
Leonard J. Gallagher
In object-oriented software development, a class is the basic unit of semantic abstraction, a component is a closely related collection of classes, and a system is an integrated collection of components designed to solve a problem. An object is an instance of a class. Each object consists of state and behavior, where state is determined by the values of State variables identified in the class definition, and behavior is determined by methods (i.e., functions or procedures), defined in the class, that operate on one or more object instances to read or modify their state variables. Objects from different classes communicate by sending messages to one another, where a message is a request to invoke one of the recipient object's methods. Conformance testing of object-oriented software is often done in three stages: unit testing, to ensure that the individual methods of a class are properly defined over all possible object instances; component testing, to ensure that methods restricted to the component under test operate as specified by rules of how the component should behave and that messages to external objects are properly sent; and system testing, to ensure that the entire system behaves as specified by some overall system functional specification. Both component testing and system testing rely heavily on integration testing, which ensures that messages from objects in one class or component are sent and received in the proper order and have the intended effect on the state of the external object that receives the message. This new work is strongly influenced by the work of Hong, Kwon, and Cha, who model a single object class as a finite state machine, transform that representation into a data flow graph that explicitly identifies the definitions and uses of each state variable of the class, and then apply conventional data flow coverage criteria and testing techniques to produce a collection of abstract test cases that can be used to test conformance of the given class to its functional specification. This paper extends those ideas to an arbitrary number of classes and components, allowing multiple object instances for each class. It introduces flexible representations for message sending and receiving among objects from different classes and allows parallel processing among any, or all, classes and components. The approach presented herein relies on finite state machines, database schemas and modeling techniques, database processing techniques, and algorithms for analysis and traversal of directed graphs. A prototype implementation of the approach demonstrates its effectiveness on non-trivial, real-world problems.
IEEE Transactions on Software Engineering
conformance testing, data flow graph, data modeling, finite state machine, object-oriented, software testing, statistical methods
Conformance Testing of Object-Oriented Components Specified by State/Transition Classes, IEEE Transactions on Software Engineering
(Accessed November 28, 2023)