一种基于动态依赖关系的类集成测试方法  被引量:12

An Approach for Class Integration Testing Based on Dynamic Dependency Relations

在线阅读下载全文

作  者:张艳梅[1] 姜淑娟[1] 张红昌[1] 

机构地区:[1]中国矿业大学计算机科学与技术学院,江苏徐州221116

出  处:《计算机学报》2011年第6期1075-1089,共15页Chinese Journal of Computers

基  金:国家自然科学基金(60970032);教育部科学技术研究重点项目(108063);江苏省自然科学基金(BK2008124);江苏省"青蓝工程";江苏省研究生培养创新工程项目(CX10B_157Z)资助

摘  要:类间集成测试是面向对象软件测试的重要组成部分,合适的测试顺序能够极大地节省测试成本.类间依赖关系构成环路的情况下,需要删除某些依赖关系以消除环路,同时需要引进测试桩.忽略类间动态依赖关系导致测试桩的数目不足,难以完成测试.文中提出一种基于动态依赖关系的类集成测试方法.首先分析了类之间的静态依赖和动态依赖关系;然后在保证测试桩的数目尽可能少的前提下,给出了边的删除规则以及消除由静态依赖关系和动态依赖关系形成的环路的算法,在此基础上,进一步提出测试顺序分配策略和算法;最后针对提出的方法开发了基于测试级的类测试序列自动生成工具——TLOG.实验结果表明:该方法较其它方法需要较少的测试桩,测试效率有明显提高.Class integration testing is an important part in object-oriented software testing. An appropriate test order for software testing can reduce test cost. In the presence of cyclic dependency calls, the test order problem can be solved by removing relationships to break cycles and then create test stubs. There are insufficient test stubs to complete testing if ignoring dynamic dependency relations. In this paper, an approach for class integration testing based on dynamic dependency is proposed. First, inter-class static and dynamic dependencies are analyzed. Then, under the premise of minimizing the number of test stubs, rules of edge deletion are given, in addition, an algorithm of eliminating the cycles that formed by static and dynamic dependency is presented. Furthermore, an integration testing order strategy and an algorithm are given. Finally, the whole approach is implemented in a test levels order generator TLOG. The experiment results show that the method requires less test stubs than others and improves the test efficiency obviously.

关 键 词:集成测试 测试顺序 测试桩 动态依赖 测试级 

分 类 号:TP311[自动化与计算机技术—计算机软件与理论]

 

参考文献:

正在载入数据...

 

二级参考文献:

正在载入数据...

 

耦合文献:

正在载入数据...

 

引证文献:

正在载入数据...

 

二级引证文献:

正在载入数据...

 

同被引文献:

正在载入数据...

 

相关期刊文献:

正在载入数据...

相关的主题
相关的作者对象
相关的机构对象