摘要
针对软件中2路并发行为的测试序列生成方法,提出一种基于面向测试着色Petri网(testing-oriented colored Petri net,To CPN)。根据被测软件系统需求构建ToCPN模型,即系统模型,并将待测行为采用着色Petri网(colored Petri net,CPN)进行描述,形成待测行为模型;提出待测行为模型到系统模型的状态投影算法、针对极大状态结点和极小状态结点的状态匹配算法及一系列路径搜索算法,基于以上算法构建出针对2路并发行为的测试序列生成方法。该方法针对待测行为自动生成测试序列,对待测行为所在的2路并发行为的全部执行组合实现完全覆盖且不存在任何冗余,一定程度上解决了软件测试中的状态爆炸问题。对上述算法的有效性提供了证明,并结合测试实践,分析说明了该方法具备明显强于随机漫步(random walk)等其他方法的效果。
A 2-Way concurrent behavior guided test sequences generation method for software testing is proposed,which is based on testing-oriented colored Petri net (ToCPN) models.Firstly,ToCPN model for software specification is constructed,called system model; and behavior under testing (BUT) is modeled with colored Petri net (CPN),called BUT model.A state projection algorithm from BUT model to system model is defined; a matching algorithm between maximal state node and minimal state node is proposed; a series of path searching algorithms in the state space of protocol model are shown.And our 2-Way concurrent behavior guided test sequence generation method is made up of these algorithms.Test sequences generated from this method cover all execution ways of BUT and do not contain any redundancy.The state explode problem in software testing is solved to a certain extent.The effectiveness of the method is proved formally,and practices show that the effect of this method is better than other methods such as random walk.
出处
《重庆邮电大学学报(自然科学版)》
CSCD
北大核心
2014年第6期727-736,共10页
Journal of Chongqing University of Posts and Telecommunications(Natural Science Edition)
基金
国家自然科学基金(61163011)
内蒙古自然科学基金(2012MS0922)~~