深度优先搜索算法生成测试用例的改进技术
An Improved Technique for Generating Test Cases with Depth-First Search Algorithms
摘要: 为保证系统软件的质量,弥补目前测试用例生成方法的不足,提高用例生成的准确性和完整性,本论文以某软件为典型代表和应用对象对国内外测试用例生成技术进行研究,并针对业务控制流、数据流和树形结构图的构造方法进行探索,结合深度优先搜索算法和实际应用要求,对传统的深度优先搜索算法进行优化改进,在每个分支节点增加加权参数,避免节点存在多条路径时丢失其他节点到该节点的路径覆盖数据,以便可以遍历到所有数据分支,使其快速搜索有效测试用例,覆盖测试需求。
Abstract: Software test is an effective method to ensure the quality of software; the test case generation is the key of software testing, in order to guarantee the quality of the system software, make up for the inadequacy of the method to generate test cases, improve the accuracy and integrity of the generated cases. Taking some software of aerospace as the typical representative and application object, the test case generation technology at home and abroad is studied to explore the method of business control flow, data flow and the tree structure view. Combined with the depth first search algorithm and the actual application requirements, the traditional depth-first search algorithm is optimized to improve, make its rapid search effective test cases, and cover with test requirements.
文章引用:王婷婷, 胡勇, 王晨光, 侯磊, 刘芸, 孟伟. 深度优先搜索算法生成测试用例的改进技术[J]. 计算机科学与应用, 2019, 9(7): 1245-1254. https://doi.org/10.12677/CSA.2019.97140

参考文献

[1] 唐滔, 钟华. 基于会话的Web应用测试方法[J]. 中国科技博览, 2011(3): 55-56.
[2] 韩璐. 基于Web用户行为的测试用例生成技术研究与实现[D]: [硕士学位论文]. 郑州: 郑州大学, 2016: 1-4.
[3] Offutt, J., Liu, S., Abdurazik, A. and Ammann, P. (2003) Generating Test Data from State Based Specifications. The Journal of Software Testing, Verification and Reliability, 13, 25-53. [Google Scholar] [CrossRef
[4] 邓名杰. 基于数据流分析的测试用例自动生成技术[D]: [硕士学位论文]. 大连: 大连海事大学, 2009: 3-6.
[5] 曹文静, 徐胜红. 基于数据流图的测试用例生成技术研究[C]//中国通信学会青年工作委员会. 2009通信理论与技术新发展–第十四届全国青年通讯学术会议. 北京: 电子工业出版社, 2009: 145-147.
[6] 黄丽芬. 软件测试数据自动生成算法的仿真研究[J]. 计算机仿真, 2012, 29(10): 245-382.
[7] 高莉, 李龙澎. 基于UML状态图的测试技术研究[J]. 计算机技术与发展, 2009(5): 68-71.