Information Technology Reference
In-Depth Information
(Testing Object-orienTed systEms with the Unifed Modeling Language) system
test methodology (Briand and Labiche 2001 ). System test requirements are derived
from UML analysis artifacts such as use cases, their corresponding sequence and
collaboration diagrams, class diagrams and from OCL used across all these arti-
facts. This approach is not automatic and is meant for system testing, whereas the
proposed approach is targeted toward integration testing related to interactions and
behaviors of objects. Offutt and Abdurazik developed a technique for generating
test cases for code rather than designs from a restricted form of UML state dia-
grams. The approach performs a limited form of class-level testing, and it does not
directly support testing of object interactions. They have also developed a criterion
for dynamic testing that involved message sequence paths. They adapt traditional
data flow coverage criteria (e.g. all definition—uses) in the context of UML
Collaboration Diagrams, but do not address test case generation. We use a different
criterion named border testing criteria. Also, our approach generates test data. To
our knowledge, no other approaches in UML testing address automatic test data
generation (Offutt and Abdurazik 1999 ). Scheetz et al. developed an approach to
generating system (black box) test cases for code from UML class diagrams
(Scheetz et al. 1999 ). Many others have proposed methods for generating test case
using UML statechart diagrams.
The scheme for generating Test Cases from collaboration diagram is as shown
in Fig. 10.2 . There are two major steps in the test data generation algorithm named
Distinction and Halving. Each input variable xi of a given input is increased/
decreased by the value UNITxi, while keeping all the other input variables con-
stant. If path P is not traversed for the modified input we say that constraint
violation has occurred. If the function F has decreased and constraint violation has
not occurred, then the given input variable and the appropriate direction is
Collaboration
Diagram
Select
Predicate
Transform
Predicate
Extension
Distinction
Refinement
Halving
Test Cases
Fig. 10.2
Scheme for test case generation from collaboration diagram
Search WWH ::




Custom Search