首页 | 本学科首页   官方微博 | 高级检索  
相似文献
 共查询到18条相似文献,搜索用时 234 毫秒
1.
张功杰  巩敦卫  姚香娟 《软件学报》2015,26(10):2504-2520
为数众多的变异体产生的高昂测试代价严重影响了变异测试技术在实际程序中的应用.为了大幅度减少弱变异测试中变异体的数量,提出基于统计占优分析的变异体约简方法.该方法首先利用变异前后的语句构造变异分支,并将所有变异分支集成到原程序中,形成新的被测程序;然后,通过统计测试用例对各个变异分支的覆盖信息,确定变异分支之间的占优关系;最后得到非被占优分支集,其对应的变异体就是约简后的变异体.将该方法用于8个程序的测试,结果表明:该方法能够约简平均90%的变异体,从而显著提高了变异测试的效率.  相似文献   

2.
变异测试通过执行变异体评价给定测试用例集的质量。然而,一定比例的等价变异体,不仅增加变异测试成本,也影响测试用例评价结果的准确性。鉴于此,提出基于弱变异分析的方法,以有效检测等价变异体。所提方法将变异前后语句组合为条件语句,以反映杀死变异体的必要性条件,并构造变异分支;将所有变异分支集成到原程序中;通过分析变异分支的可满足性,判定等价变异体。将所提方法用于6个程序的实验,结果表明,所提方法能够有效检测等价变异体。  相似文献   

3.
测试是提高软件可靠性的重要方法.消息传递并行程序中存在的不确定通信语句,使得进程执行顺序具有不确定性,这增加了测试该类程序的难度.鉴于进程执行顺序对目标路径覆盖难易程度的影响,本文研究消息传递并行程序多路径覆盖调度序列排序方法,以提高多路径覆盖测试数据生成的效率.首先,在每个调度序列下,以每个采样的程序输入执行程序,生...  相似文献   

4.
王曙燕 《计算机应用研究》2021,38(5):1487-1490,1497
针对基于程序谱错误定位方法完全依赖于测试用例的语句覆盖信息导致错误定位效率低下的问题,提出了一种基于变异测试技术的程序谱错误定位方法。在原有语句怀疑度计算方法的基础上,增加了程序变异后执行结果与原程序执行结果不同的测试用例变化情况的分析。此外,为解决程序变异后产生的变异体数量巨大而导致执行代价过大的问题,提出了根据变异位置约简变异体的策略。实验结果表明,与几种基于程序谱的程序错误定位方法相比,该方法的错误定位代价最低,能有效提高错误定位的效率。  相似文献   

5.
实际测试用例一般不能满足变异测试充分,但遗传算法搜索空间较大,可使用其生成变异测试充分度较高的测试用例集.适应值函数的构造使用分支函数插装法.首先根据杀死弱变异体的必要性条件,构造必要性条件分支函数,插装于源程序中;然后根据可达性条件,构造可达性条件的分支函数并插装.使用基于面向路径的遗传算法来搜索杀死弱变异体的测试用例.将终止条件改为程序最终结果的不同,插装函数不变,生成满足条件的强变异测试用例.对于多重弱变异,按熙可达路径实施等价类划分,每一个等价类采用与单重弱变异相同的方法.实验结果表明,遗传算法可生成杀死各类变异体的测试用例,优于随机生成的测试用例.  相似文献   

6.
针对为数较多的测试用例增加了回归测试成本的问题,提出一种基于弱变异准则的测试用例约简方法。首先,基于弱变异准则获得测试用例和变异分支关系矩阵;然后,重复约简4种无效测试需求和子集测试用例;最后,结合人工鱼群算法选择当前最优测试用例,并且交替执行简化和测试用例选择操作直至覆盖所有测试需求。该方法针对6个经典程序与贪心算法和HGS算法相比,基于弱变异准则并且不改变或稍微改变变异评分的条件下,约简率分别提高了73.4%和8.2%,且耗时分别降低了25.3%和56.1%。实验结果表明,所提方法在回归测试中可有效约简测试用例,降低测试代价。  相似文献   

7.
针对检测缺陷的测试数据生成效率低下问题,提出变异测试和路径覆盖测试技术结合的测试数据生成方法。首先,采用变异测试技术生成的变异分支融入程序,生成新的被测程序;然后,在原路径集中挑选目标路径,通过分析变异分支与路径关联关系,将变异分支融入路径。最后,基于遗传算法生成覆盖路径的测试数据。实验结果表明,多种群遗传算法生成测试数据的时间,比单种群遗传算法节约了41.15%。由此可见,对于覆盖多路径测试数据生成,多种群遗传算法的效率比单种群遗传算法高。  相似文献   

8.
随着软件规模和复杂度的不断提高,软件的质量问题成为了关注的焦点,如何高效地找出软件中的错误成为一个亟需解决的问题。错误定位是软件质量保证的重要途径之一,近年来已经成为软件工程中一个非常重要的研究课题。基于变异测试的错误定位通过比较原程序和对应变异体的差异来计算每条语句的怀疑度,再由怀疑度大小进行排序,程序员根据排序逐个检查找出错误语句。汇总近7年(2012-2018)国内外的基于变异测试的错误定位技术的研究成果,介绍了错误定位的基本方法,介绍基于变异测试的错误定位思想,从变异算子、变异体及等价变异体3个方面对已有的研究工作进行分类归纳和总结,探讨了基于变异测试的错误定位未来可能的研究方向、机遇和挑战。  相似文献   

9.
巩敦卫  钟超群  姚香娟 《软件学报》2015,26(8):1925-1936
基于占优关系的可测试性转化,是将目标语句覆盖问题转化为位于该语句之前的占优语句(集)覆盖问题,能够对含有标志变量的程序进行测试.但是当占优语句(集)不止一个时,如何从这些语句(集)中选择最容易覆盖的作为新的目标语句(集),至今没有有效的方法,从而限制了可测试性转化的应用范围.研究了占优语句(集)选择问题,提出了基于覆盖难度的占优语句(集)选择方法.首先,提出评价语句覆盖难度的4个指标,并给出这些指标的计算方法;然后,基于上述指标,利用Topsis方法排序,选择最容易覆盖的占优语句(集);最后,将所提出的方法应用于多个基准与工业程序测试,实验结果表明,覆盖基于该方法选择的占优语句(集)能够显著提高测试数据生成的效率.  相似文献   

10.
在并行程序测试中,测试输入和线程交互时序是影响并行错误检测的两个关键因素。以缩减并行错误检测的输入空间为目标,给出一种基于变异测试的测试用例最小化算法。首先对并行程序进行研究,选取与并行错误密切相关的9个变异算子,并以此为基础为待测程序生成多种变异体;采用JPF作为线程调度工具来执行测试用例,根据变异评分与平均时间成本对测试用例进行排序,在优化后的测试用例集中选取检测能力不重复的测试用例,从而得到面向并行错误检测的最小测试用例集。实验结果证明,该方法能有效减小测试用例集的规模,并大幅缩短运行时间,从而提高了并行程序的测试效率。  相似文献   

11.
Because of the computationally expensive cost of mutation testing, automated system support is indispensable for conducting mutation testing. Mutation systems can be classified into interpretive and noninterpretive, but recent systems are noninterpretive. Weak mutation is a well‐known cost reduction method of mutation testing, but it is not directly applicable to noninterpretive mutation systems. To address the problem and take advantage of the efficiency of weak mutation, this paper presents a combined weak and strong mutation for noninterpretive Java mutation systems. The new term ‘serialmutant’ is defined as a specialized program to conduct weak mutation against all mutants in an execution and report only weakly killed mutants as strong mutation candidates. Then strong mutation is conducted only for those reported mutants. The paper also describes an implementation based on a previous Java mutation tool, MuJava. Method‐level mutation operators for Java are also redesigned. Experimental results show that the proposed approach efficiently improves the mutation cost in a noninterpretive mutation system. Copyright © 2012 John Wiley & Sons, Ltd.  相似文献   

12.
规约变异测试从软件功能的角度,对规约进行分析,从而揭示规约中存在的问题。本文提出一种基于UML状态图的变异测试方法,针对每种变异算子,分析其是否会引入冲突,进而有效避免不合理的变异操作;分析了每种变异算子产生等价变异体的条件,能够在生成变异体的同时检测并移除等价变异体,进而减少其对测试过程的影响;给出了杀掉每种变异体所需满足的条件,可在此基础上产生杀掉特定变异体所需的测试用例,从而提高测试用例集的质量。在此基础上,根据变异算子的实际功能,整合了功能相同的算子,减少了变异算子的数量,从而进一步降低了变异测试的开销。实验结果表明,本方法能够较好地提高测试用例的质量,进而提升测试的效率。  相似文献   

13.
Parallel programs present some features such as concurrency, communication and synchronization that make the test a challenging activity. Because of these characteristics, the direct application of traditional testing is not always possible and adequate testing criteria and tools are necessary. In this paper we investigate the challenges of validating message‐passing parallel programs and present a set of specific testing criteria. We introduce a family of structural testing criteria based on a test model. The model captures control and data flow of the message‐passing programs, by considering their sequential and parallel aspects. The criteria provide a coverage measure that can be used for evaluating the progress of the testing activity and also provide guidelines for the generation of test data. We also describe a tool, called ValiPar, which supports the application of the proposed testing criteria. Currently, ValiPar is configured for parallel virtual machine (PVM) and message‐passing interface (MPI). Results of the application of the proposed criteria to MPI programs are also presented and analyzed. Copyright © 2008 John Wiley & Sons, Ltd.  相似文献   

14.
Mutation testing is a technique for testing software units that has great potential for improving the quality of testing, and thereby increasing the ability to assure the high reliability of critical software. It will be shown that recent advances in mutation research have brought a practical mutation testing system closer to reality. One recent advance is a partial solution to the problem of automatically detecting equivalent mutant programs. Equivalent mutants are currently detected by hand, which makes it very expensive and time-consuming. The problem of detecting equivalent mutants is a specific instance of a more general problem, commonly called the feasible path problem, which says that for certain structural testing criteria some of the test requirements are infeasible in the sense that the semantics of the program imply that no test case satisfies the test requirements. Equivalent mutants, unreachable statements in path testing techniques, and infeasible DU-pairs in data flow testing are all instances of the feasible path problem. This paper presents a technique that uses mathematical constraints, originally developed for test data generation, to detect some equivalent mutants and infeasible paths automatically. © 1997 John Wiley & Sons, Ltd.  相似文献   

15.
Most message passing parallel programs employ logical process topologies with regular characteristics to support their computation. Since process topologies define the relationship between processes, they present an excellent opportunity for debugging. The primary benefit is that process behaviours can be correlated, allowing expected behaviour to be abstracted and identified, and undesirable behaviour reported. However, topology support is inadequate in most message passing parallel programming environments, including the popular Message Passing Interface (MPI) and the Parallel Virtual Machine (PVM). Programmers are forced to implement topology support themselves, increasing the possibility of introducing errors. This paper proposes a trace‐ and topology‐based approach to parallel program debugging, driven by four distinct types of specifications. Trace specifications allow trace data from a variety of sources and message passing libraries to be interpreted in an abstract manner, and topology specifications address the lack of explicit topology knowledge, whilst also facilitating the construction of user‐consistent views of the debugging activity. Loop specifications express topology‐consistent patterns of expected trace events, allowing conformance testing of associated trace data, and error specifications specify undesirable event interactions, including mismatched message sizes and mismatched communication pairs. Both loop and error specifications are simplified by having knowledge of the actual topologies being debugged. The proposed debugging framework enables a wealth of potential debugging views and techniques. Copyright © 2004 John Wiley & Sons, Ltd.  相似文献   

16.
Developing high‐quality, error‐free message‐passing concurrent programs is not trivial. Although a number of different primitives with associated semantics are available to assist such development, they often increase the complexity of the testing process. In this paper, we extend our previous test model for message‐passing programs and present new structural testing criteria, taking into account additional features used in this paradigm, such as collective communication, non‐blocking sends, distinct semantics for non‐blocking receives, and persistent operations. Our new model also recognizes that sender primitives cannot always be matched with every receive primitive. This improvement allows us to remove statically a significant number of infeasible synchronization edges that would otherwise have to be analyzed later by the tester. In this paper, the test model is presented using the Message‐Passing Interface standard; however, our new model has been designed to be flexible, and it can be configured to support a range of different message‐passing environments or languages. We have carried out case studies showing the applicability of the new test model to represent message‐passing programs and also to reveal errors, mainly those errors related to inter‐process communication. In addition to increasing the number of features supported by the test model, we have also reduced the overall cost of testing significantly. Our case studies suggest that the number of synchronization edges can be reduced by up to 93%, mainly by eliminating infeasible edges between unmatchable communication primitives. The main contribution of the paper is to present a more flexible test model that provides improved coverage for message‐passing programs and at the same time reduces the cost of testing significantly. Copyright © 2012 John Wiley & Sons, Ltd.  相似文献   

17.
在应用基于代数规约测试类时,虽然可以有效解决测试数据生成和测试结果判断这两个测试难题,但是,因为该方法常常随机生成测试数据,会导致对于同一待测试类两次测试会得到不同的测试效果。为克服这个缺陷,提出应用数据变异方法,对已生成的测试用例进行变异。变异测试实验表明:该方法能够有效地改善代数测试方法的测试效果。  相似文献   

18.
在对程序分片技术研究的基础上,提出一种新的片变体测试方法。通过实例说明,该方法能更有效地提高变体测试的准确性及测试效率。  相似文献   

设为首页 | 免责声明 | 关于勤云 | 加入收藏

Copyright©北京勤云科技发展有限公司  京ICP备09084417号