针对Web应用的功能测试问题,提出一种基于用例和顺序图的Web应用建模与测试方法。使用统一建模语言(UML)将用例图分层地扩展为用例迁移模型(UCTM),利用顺序图自上而下描述UCTM中的每个用例,将顺序图自动转换为受限有向图(RDG)。为控制状态空间爆炸,提出约束消息覆盖准则(CMC)。结果表明,由RDG生成的测试用例能满足CMC,CMC可控制测试用例的数量。
Aiming at the function test problem of Web application,this paper proposes a Web application modeling and test method based on use case and sequence diagram.It extends use case diagram hierarchically into Use Case Transition Model(UCTM) by Unified Modeling Language(UML).Each use case of UCTM is described by sequence diagram,which can be converted automatically into a Restricted Directed Graph(RDG).In order to control status space explosion,it proposes a piece of Constraint Message Coverage criterion(CMC),test case generated from RDG can satisfy CMC,and CMC can control the number of test case.