期刊文献+

程序不变量到断言的自动转换方法研究及其应用 被引量:2

ON AUTOMATICALLY CONVERTING PROGRAM INVARIANT TO ASSERTION AND ITS APPLICATION
在线阅读 下载PDF
导出
摘要 程序不变量可以揭示程序的内部属性和动态执行情况,已经成功应用于软件测试用例的生成与约简。然而,每新增一个用例都要在整个测试用例集合上重新提取程序不变量,时间开销较大。提出一种基于正则表达式的将程序不变量自动转换为对应断言的方法,并利用断言判断新用例是否冗余,仅当新用例非冗余时才提取程序不变量,从而大幅度减小时间开销。将这种基于断言的测试方法应用于回归测试,可以有效约简测试用例集合,识别程序改动所影响的元素,进而发现潜在的程序错误。实验结果表明,与其它测试用例选择方法相比,该方法时间消耗小、测试用例集合约简率高、揭错能力强。 Program invariants,which can reveal internal properties and dynamic execution situations of the program,have been successfully applied to generation and reduction of software test case.However,the program invariants have to be re-extracted from entire test suite for every new test case added,this causes a heavy time cost.This paper proposes a novel method to automatically convert program invariants into corresponding assertions,which is based on regular expression.Assertions are used to judge whether a new test case is the redundancy,this saves a great deal of time since the program invariants are re-extracted only when the new test case is not the redundant one.Applying this assertion-based testing method to regression test,the test suite can be effectively reduced,and the elements affected by the program modification can be identified,thus the latent program errors can be further found as well.Experiment results show that compared with other test case selection techniques,the method proposed in the paper costs less time and has a higher test suite reduction rate and stronger errors exposing ability.
出处 《计算机应用与软件》 CSCD 北大核心 2012年第11期177-180,189,共5页 Computer Applications and Software
基金 安徽省自然科学基金项目(11040606M131)
关键词 程序不变量 断言 回归测试 错误识别 测试用例集合约简 Program invariant Assertion Regression test Error identification Test suite reduction
  • 相关文献

参考文献12

  • 1Ernst M D. Dynamically discovering likely program invariants [ D ]. Seattle, Washington: Department of Computer Science and Engineering, University of Washington, 2000.
  • 2DAIKON version 4.6.2 [ EB/OL]. http://groups, csail, mit. edu/ pag/daikon.
  • 3Ernst M D, Perkins J H, Guo P J, et al. The daikon system for dynamic detection of likely invariants[J]. Science of Computer Programming, 2007, 69(1 -3) : 35 -45.
  • 4Zeng F, Cao Q, Mao L, et al. Test case generation based on invariant extraction [ C ]//Proceedings of the 5th International Conference on Wireless communications, networking and mobile computing. Beijing, China,2009:1-4.
  • 5Pan N, Zeng F, Huang Y. Test case reduction based on program invariant and genetic algorithm[ C ]//Proceedings of the 6th International Conference on Wireless communications, networking and mobile com- puting. Chengdu, China, 2010:1 -5.
  • 6曾凡平,袁园,潘能刚,邓超强.不变量指导的随机测试用例生成[J].小型微型计算机系统,2011,32(11):2174-2181. 被引量:3
  • 7Yuan Y, Zeng F, Zhu G, et al. Test case generation based on program invariant and adaptive random algorithm[ C ]//Proceedings of the 14th IEEE International Conference on Computational Science and Engineering ( CSE 2011 ). Dalian, China, 2011 : 274 - 282.
  • 8Graves T L, Harrold M J, Kim J M, et al. An empirical study of regression test selection techniques [ J ]. ACM Transactions on Software Engineering and Methodology, 2001, 10(2) : 184-208.
  • 9Frankl P G, Rothermel G, Sayre K, et al. An empirical comparison of two safe regression test selection techniques [ C ]//Proceedings of the 2003 International Symposium on Empirical Software Engineering ( ISESE 2003). Rome, Italy, 2003:195-204.
  • 10Rothermel G, Harrold M J. A safe, efficient regression test selection technique [ J ]. ACM Transaction on Software Engineering and Methodology, 1997, 6(2) : 173 -210.

二级参考文献14

  • 1Antonia Bertolino. Software testing research: achievements, chal- lenges, dreams[ C]. Future of Software Engineering ( FOSE '07), Minneapolis, USA, May,2007:96-114.
  • 2Alex Groce, Gerard Holzmann, Rajecv Joshi. Randomized differ- ential testing as a prelude to formal verification[C]. 29th Interna- tional Conference on Software Engineering, Minneapolis, MN, USA, 2007:626-635.
  • 3DAIKON version 4.6.2[ EB/OL]. http ://groups. csail, mit. edu/ pag/DAIKON/, 2010 -10.
  • 4Michael D Ernst. Dynamically discovering likely program invad- ants[ D]. Dept. of Computer Science and Eng., Univ. of Wash- ington, Seattle, Wash., Aug,2000.
  • 5Michael D Ernst, Jeff H Perkins, Philip J Gut), et al. The DAIKON system for dynamic detection of likely invariants [J ]. Science of Computer Programming, Dec. 2007, 69( 1-3 ) : 35-45.
  • 6Fanping Zcng, Qing Cao, Liangliang Man, et al. Test case genexa- tion based on invariant extraction[C]. In 5th International Confer- encc on Wireless Communications, Networking and Mobile Com- puting, Sept. 2009:24-26.
  • 7Christoph Csallner, Yannis Sma~gdakis. JCrasher: an automatic robustness tester for Java[ J ]. Software: Practice and Experience, Sept. 2004, 34(11) :1025-1117.
  • 8Carlos Pacheco, Shuvcndu K Lahiri, Thomas Ball. Finding errors in. NET with fcexiback-dircctcd random testing [ C ]. In ISSTA 2008: International Symposium on Software Testing and Analysis, Seattle, Washington, July 20-24, 2008:87-95.
  • 9Carlos Pacheco, Shuvcndu K Lahiri, Michael D Ernst, ct al. Fee, d- back-directed random test generation[C]. In ICSE'07: Proceed- ings of the 29th International Conference on Software Engineering, Minneapolis, MN, USA, 2007:75-84.
  • 10Rupak Majumdar and Koushik Sen. Hybrid concolic testing[ C ]. In 29th International Conference on Software Engineering ( ICSE' 07), IEEE, 2007:416-426.

共引文献2

同被引文献4

引证文献2

相关作者

内容加载中请稍等...

相关机构

内容加载中请稍等...

相关主题

内容加载中请稍等...

浏览历史

内容加载中请稍等...
;
使用帮助 返回顶部