文档详情

基于改进遗传算法的测试数据自动生成的研究.pdf

发布:2017-06-08约2.86万字共6页下载文档
文本预览下载声明
第44卷 第 3期 计 算 机 科 学 Vo1.44No.3 2017年 3月 COMPUTER SCIENCE M ar.2017 基于改进遗传算法的测试数据 自动生成的研究 高雪笛 ,。 周丽娟L 张树东L 柳昊明。 (首都师范大学信息工程学院 北京 100048) (成像技术北京市高精尖创新中心 北京 100190)。 (北京航空航天大学计算机学院 北京 100048)。 摘 要 测试数据 自动生成是软件测试的基础,也是测试 自动化技术实现的关键环节。为了提高测试 自动化的效率, 在结合测试数据 自动生成模型的基础上,提 出一种传统遗传算法的改进算法。该算法使用了自适应交叉算子和变异 算子,并引入模拟退火机制对其进行改进。同时,该算法还对适应度函数进行了合理的设计,以加速数据的优化过程。 通过三角形程序、折半查找和冒泡排序程序,与基本遗传算法、自适应遗传算法进行了比较与分析,并且对改进算法做 了性能分析。实验结果表明了该算法的实用性以及在测试数据生成中的可行性和高效性。 关键词 软件测试 ,遗传算法,哈明函数,测试数据 自动生成 中图法分类号 TP311 文献标识码 A DOI 10.11896/j.issn.1002—137X.2017.03.044 ResearchonTestDataAutomaticGenerationBasedonImprovedGeneticAlgorithm GAOXu~di’。 ZHOULi-juan·。 ZHANGShu-dong1, LIU Hao-ming3 (CollegeofInformationEngineering,CapitalNormalUniversity,Beijing100048,China) (BeijingAdvancedInnovationCenterforImagingTechnology,Beijing100190,China)。 (SchoolofComputerScienceandEngineering,Beihang University,Beijing 100048,China)。 Abstract Automatictestdatagenerationisthebasisofsoftwaretesting,anditisalsoakeylinkintheprocessoftest automationtechnology.Inordertoimprovetheefficiencyoftestingautomation.anew algorithm wasproposedto provethetraditionalgeneticalgoritmh basedonthecombinationoftestdaat automaticgenerationsystemmode1.Thea— daptivecrossoveroperatorandmumt~noperatorareused inthisalgoritmh .andthemiprovedsimulatedannealing mechanism isintroducedot improveit.Atthesanletime,thealgoritmh isalsodesignedtOfitthefitnessfunctiontoac- celeratetheoptimizationprocessofthedata.Throughhtetriangleprogram,binarysearchandbubblesortprogram,the basicgeneticalgoritmh andhteadaptivegeneticalgoritmh werecompared,andtheperformancetestwasdoneforim— provedalgorithm.Exper
显示全部
相似文档