Using model checking to generate tests from specifications

被引:161
作者
Ammann, PE [1 ]
Black, PE [1 ]
Majurski, W [1 ]
机构
[1] George Mason Univ, Informat & Software Eng Dept, Fairfax, VA 22033 USA
来源
SECOND INTERNATIONAL CONFERENCE ON FORMAL ENGINEERING METHODS, PROCEEDINGS | 1998年
关键词
D O I
10.1109/ICFEM.1998.730569
中图分类号
TP3 [计算技术、计算机技术];
学科分类号
0812 ;
摘要
We apply a model checker to the problem of test generation using a new application of mutation analysis. We define syntactic operators, each of which produces a slight variation on a given, model. The operators define a form of mutation analysis at the level of the model checker specification. A model checker generates counterexamples which distinguish the variations from the original specification. The counterexamples can easily be turned into complete test cases, that is, with inputs and expected results. We define two classes of operators: those that produce test cases from which a correct implementation must differ, and those that produce test cases with which it must agree. There are substantial advantages to combining a model checker with mutation analysis. First, test case generation is automatic; each counterexample is a complete test case. Second, in sharp contrast to program-based mutation analysis, equivalent mutant identification is also automatic. We apply our method to an example specification and evaluate the resulting test sets with coverage metrics on a Java implementation.
引用
收藏
页码:46 / 54
页数:9
相关论文
empty
未找到相关数据