Black-Box Software Testing using Module Interface Specifications

Ms. Ruth F. Abraham

Software Engineering Research Group
CRL, McMaster University,
Hamilton, Ontario, Canada L8S 4K1


This report describes the use of formal module interface specifications for black-box testing. In the selection of test cases, black-box software testing ignores the program implementation and uses only information contained in specification documents. A trace module interface specification uses the assertions about traces to describe a module's behaviour. A trace specification document provides information about a module's access-programs, including syntax, the behaviour of an object after a program invocation, definitions of return values, and error causing input. An "outsider" was given the code and a formal specification and asked to determine if the code satisfied its specification. Test cases were selected based on the conditions listed in the specification, and the specification was used to validate behaviour and return values.

Black-box testing does not assume that the specification is correct. Discrepancies between the Table Holder code and specification are recorded for evaluation by others. This black-box testing exercise uncovered many discrepancies between the code and specification, ranging from issues of notation and error handling, to design methodologies and memory management.