基于一致性测试理论的Statechart描述的测试用例自动生成
网络出版日期: 2011-05-01
Automatic Generation of Test Cases for Statechart Specification Based on the Conformance Testing Theory
Online published: 2011-05-01
本文研究Statechart描述的测试语义和测试用例的自动生成。基于Tretmans的从标记转换系统描述自
动生成测试用例的方法,我们研究如何从Statechart描述自动生成测试用例。本文的主要贡献在于建立了基
于Statechart描述的一致性测试和测试用例生成的形式化基础。为Statechart描述建立了形式化测试语义,
测试语义与传统的验证语义不同,强调可观察性和内部细节隐藏。基于形式化测试语义和测试假设,形式化
定义了系统描述和系统实现之间的一致性关系/实现关系。然后给出了基于图遍历的测试用例生成算法,对
于无环测试语义该算法可以生成完全测试集,而对于带环测试语义该算法可以生成高效率的宽泛测试集。
苗春雨1,陈丽娜2,赵建民2 . 基于一致性测试理论的Statechart描述的测试用例自动生成[J]. 计算机工程与科学, 2011 , 33(3) : 82 -89 . DOI: 10.3969/j.issn.1007130X.2011.
This paper studies testing semantics and automatic test case generation for
Statechart specification. Applying Tretmans’ approach to generate test cases for I/O automata
from labeled transition systems, we provide a solid mathematical basis for conformance testing
and automatic test case generation for Statechart specification. We introduce formal testing
semantics of Statechart specification that go beyond the semantics presented for formal
verification. These observable testing semantics can be used for general application, critical
application and realtime application. We also propose a formal conformance testing relation
based on presenting formal semantics and test hypothesis, and provide an algorithm which, for
a Statechart specification, generates a test suites. For finiteruns semantics the algorithm
can generate complete test suites, and for infiniteruns semantics only sound test suite can
be generated.
[1]Harel D. Statecharts: A Visual Formalism for Complex Systems[J]. Science of Computer
Programming, 1987, 8(3):231274.
[2]Harel D,Pnueli A. On the Development of Reactive Systems[J]. Logic and Model of
Concurrent Systems, 1984, 13:477498.
[3]Tretmans J. Test Generation with Inputs, Outputs and Repetitive Quiescence[J]. Software
Concepts and Tools, 1996, 17(3):103120.
[4]Tretmans J. Testing Concurrent Systems: A Formal Approach[C]∥Proc of CONCUR’99,
1999:4665.
[5]Tretmans J. Conformance Testing with Labelled Transition Systems: Implementation
Relations and Test Generation[J].Computer Networks and ISDN Systems, 1996, 29(1):4979.
[6]Brinksma E,Tretmans J. Testing Transition Systems: An Annotated Bibliography[C]∥Proc
of MOVEP’00, 2001:187195.
[7]Latella D, Majzik I, Massink M. Towards a Formal Operational Semantics of UML Statechart
Diagrams[C]∥Proc of FMOODS’99,1999:331347.
[8]Latella D,Massink M. A Formal Testing Framework for UML Statechart Diagrams Behaviours:
From Theory to Automatic Verification[C]∥Proc of the 6th IEEE Int’l HighAssurance
Systems Engineering Symp,2001:1122.
[9]Latella D,Massink M. On Testing and Conformance Relations of UML Statechart Diagrams
Behaviours[C]∥Proc of the ACM SIGSOFT 2002 Int’l Symp on Software Testing and
Analysis,2002:144153.
[10]Gnesi S, Latella D, Massink M. Formal TestCase Generation for UML Statecharts[C]∥
Proc of ICECCS’04,2004:7584.
[11]Leveson N G, Heimdahl M P E,Hildreth H,et al. Requirements Specification for Process
Control Systems[J]. IEEE Transactions on Software Engineering, 1994, 20(9):684707.
[12]Selic B, Gullekson G, Ward P T. RealTime ObjectOriented Modeling[M]. John Wiley &
Sons, 1994.
[13]Booch G, Rumbaugh J, Jacobson I. The Unified Modeling Language User Guide[M]. Addison
Wesley, 1998.
[14]Harel D, Pnueli A, Schmidt J P, et al. On the Formal Semantics of Statecharts(Extended
Abstract)[C]∥Proc of Logic in Computer Science, 1987:5464.
[15]Harel D,Naamad A. The STATEMATE Semantics of Statecharts[J]. ACM Transactions on
Software Engineering Methodology, 1996, 5(4):293333.
[16]董威, 王戟, 齐治昌.UMLStatecharts的模型检验方法[J]. 软件学报, 2003, 14(4):750756.
[17]Bernot G. Testing Against Formal Specifications: A Theoretical View[C]∥Proc of
TAPSOFT’91,1991:99119.
[18]Tretmans J. A Formal Approach to Conformance Testing:[Ph D Thesis][D].University of
Twente (NL), 1992.
/
| 〈 |
|
〉 |