计算机科学 ›› 2012, Vol. 39 ›› Issue (4): 139-141.

• 软件工程 • 上一篇    下一篇

基于复杂系统遗传算法的多路径覆盖测试用例生成方法

于博,姜淑娟,张艳梅   

  1. (中国矿业大学计算机科学与技术学院 徐州221116)
  • 出版日期:2018-11-16 发布日期:2018-11-16

Multiple Paths Test Case Generation Based on Complex System Genetic Algorithm

  • Online:2018-11-16 Published:2018-11-16

摘要: 针对目前复杂系统多路径覆盖测试用例生成方法较少的问题,提出一种新的基于复杂系统的多路径覆盖测 试用例生成方法。首先改进遗传算法,在种群进化中对父代选择、个体进化的学习能力和种群的自适应更新方法进行 改进,以有效避免算法收敛过慢或者“早熟”现象。然后根据多路径覆盖测试的特点与要求,设计基于路径匹配的适应 度函数,使得运行一次算法便可生成覆盖多条目标路径的多个测试用例。最后将该方法用于几个基准程序。实验结 果表明,与已有方法比较,此方法的测试用例生成效率显著提高。

关键词: 复杂系统,多路径覆盖,测试用例生成,遗传算法,适应度函数

Abstract: In the light of the lack of effective methods to generating test case for multiple paths coverage based on com- plex system, we proposed a novel evolutionary generation approach of test case for multiple paths coverage. First, gener- is algorithm was improved; the ability of parent evolutionary selection, individual evolution and adaptive update method of populations were improved in the evolution of population, which cound solve the algorithm for early slow convergence or premature effectively. And then, according to the features and requirements of multiple paths coverage, fitness func- lion based on path-match was designed so that in one run, it was able to generate multiple test data to cover multiple target paths. Finally, the proposed approach was applied into several benchmark programs. The experimental results show that the proposed approach can improve the efficiency of test data generation effectively.

Key words: Complex system,Multiple paths coverage,Test case generating,Genetic algorithms,Fitness function

No related articles found!
Viewed
Full text


Abstract

Cited

  Shared   
  Discussed   
No Suggested Reading articles found!