首页 | 本学科首页   官方微博 | 高级检索  
相似文献
 共查询到20条相似文献,搜索用时 15 毫秒
1.
测试数据生成是软件测试的核心与关键,本文介绍了迭代松弛法以及对迭代松弛法进行改进,改进后的方法比原方法生成测试数据的能力更强,不仅能够用于白盒测试数据的自动生成,还能够用于黑盒测试数据的自动生成。在此基础上提出一个面向路径的测试数据生成框架。并讨论该框架在单元测试、组装测试中的应用。  相似文献   

2.
为了实现对软件配置项和软件系统的接口测试的测试用例自动生成,建立了基于通信协议的接口测试用例自动生成框架,对该生成框架的输入模型和算法集合进行研究。提出了基于通信协议的接口测试用例生成框架的输入模型,并在输入模型中建立数据帧之间的一级关联矩阵和数据帧内字段间的二级关联矩阵。以输入模型为基础,说明发送端和接收端的接口测试用例自动生成算法。结合实际项目中的通信协议,介绍了如何将通信协议信息转换至输入模型,如何通过算法集合自动生成测试用例集。实验结果表明:基于通信协议的接口测试用例自动生成框架生成的接口测试用例可以替代人工生成的接口测试用例,极大地提高了软件接口测试工作的效率。  相似文献   

3.
An integrated automatic test data generation system   总被引:3,自引:0,他引:3  
The Godzilla automatic test data generator is an integrated collection of tools that implements a relatively new test data generation method—constraint-based testing—that is based on mutation analysis. Constraint-based testing integrates mutation analysis with several other testing techniques, including statement coverage, branch coverage, domain perturbation, and symbolic evaluation. Because Godzilla uses a rule-based approach to generate test data, it is easily extendible to allow new testing techniques to be integrated into the current system. This article describes the system that has been built to implement constraint-based testing. Godzilla's design emphasizes orthogonality and modularity, allowing relatively easy extensions. Godzilla's internal structure and algorithms are described with emphasis on internal structures of the system and the engineering problems that were solved during the implementation.Parts of this research were supported by Contract F30602-85-C-0255 through Rome Air Development Center while the author was a graduate student at the Georgia Institute of Technology.  相似文献   

4.
一种基于约束的变异测试数据生成方法   总被引:1,自引:0,他引:1  
作为衡量测试用例集完备性的测试策略,变异测试是一种“面向缺陷”的单元测试技术,主要用来生成完备的测试用例集.其中面向路径测试数据生成技术通过约束系统构造和求解过程实现用例集生成,是一种高效的测试用例生成技术.但目前大部分面向路径测试用例生成技术只考虑了程序语句间的控制依赖,即通过对控制流图的分析来构建约束系统,而忽略了语句间的数据依赖对约束系统的影响.充分考虑两种依赖关系,针对域削减的测试数据生成技术进行了改进,提出了一种考虑数据依赖的域削减方法.实验表明,这种方法在变异测试数据生成的成功率和执行效率上都有较大程度的提高.  相似文献   

5.
基于量子遗传算法的软件测试数据自动生成   总被引:2,自引:0,他引:2  
测试数据的自动生成是测试阶段最关键的技术问题,改进软件测试方法,对提高软件测试的自动化程度具有十分重要的现实意义;在测试数据的自动生成的方法中,遗传算法虽然取得了较好的效果,但是这种算法存在缺陷和局限性,而量子遗传算法改善了其不足之处;应用量子遗传算法解决软件测试数据生成问题,克服了传统的以测试数据为核心的测试方法的不足和缺陷,实验结果表明量子遗传算法的测试用例生成效率高于遗传算法;所以,量子遗传算法可以作为一种较为理想的算法进行测试数据的自动生成,对软件测试中的测试数据自动生成具有很强的使用价值。  相似文献   

6.
A rule-based software test data generator   总被引:3,自引:0,他引:3  
Rule-based software test data generation is proposed as an alternative to either path/predicate analysis or random data generation. A prototype rule-based test data generator for Ada programs is constructed and compared to a random test data generator. Four Ada procedures are used in the comparison. Approximately 2000 rule-based test cases and 100000 randomly generated test cases are automatically generated and executed. The success of the two methods is compared using standard coverage metrics. Simple statistical tests showing that even the primitive rule-based test data generation prototype is significantly better than random data generation are performed. This result demonstrates that rule-based test data generation is feasible and shows great promise in assisting test engineers, especially when the rule base is developed further  相似文献   

7.
基于解空间树的组合测试数据生成   总被引:12,自引:1,他引:12  
在组合覆盖测试模型的基础上提出:将所有的可用测试数据表示为一棵解空间树,利用回溯法对解空间树进行路径搜索来生成测试数据,然后使用贪心算法补充生成测试数据,以满足两两组合覆盖标准.并且实现了基于该方法的测试数据生成工具,所生成的测试数据集与同类工具相比具有一定的特点和优势.  相似文献   

8.
一种结构测试数据自动生成的框架   总被引:1,自引:0,他引:1       下载免费PDF全文
针对结构测试中控制流和数据流覆盖测试数据的生成都可以归结为面向路径的测试数据生成的问题,提出了一个通用的基于控制流和数据流的结构测试数据自动生成的框架。该框架根据控制流和数据流测试中所采用的覆盖标准优化选取测试路径,并以改进后的迭代松弛法为核心,对所选取的路径生成测试数据。以基于路径覆盖、分支覆盖和数据流覆盖测试数据自动生成这3种算法为核心,开发了一个测试数据自动生成的框架原型。实验结果表明该框架是可行的。  相似文献   

9.
针对交互式软件的频繁交互、状态复杂等特点,基于功能测试和层次型结构,从需求规范中提取基于操作流程的功能组件,通过映射、重组测试脚本,导入测试数据,并自动生成测试用例。功能组件的构建具有层次型结构的特点,即一个功能组件可以包含一个或多个功能组件,更大程度地共享了测试脚本。  相似文献   

10.
一种基于测试需求约简的测试用例集优化方法   总被引:17,自引:1,他引:17  
测试用例集优化的目标是用尽可能少的测试用例充分满足给定的测试目标.针对给定的测试目标,获得精简的测试需求集有助于提高测试用例集优化的效率和效果.从测试需求约简的角度考虑测试用例集优化,首先给出可以精确描述测试需求间相互关系的测试需求约简模型;基于此模型,提出一种测试需求约简方法,可以获得精简测试需求集,作为测试用例集生成和约简的基础,从而实现测试用例集优化.实验结果表明,测试需求约简有助于获得规模较小的测试用例集,实现系统、科学、有效的测试.  相似文献   

11.
一种Web服务的测试数据自动生成方法   总被引:31,自引:1,他引:31  
软件测试是保证Web服务质量的重要技术手段.测试数据生成是Web服务测试的重要内容.测试数据的质量将直接影响Web服务测试的效率和成本.文章基于合约式设计的 Web服务测试技术,提出一种 Web服务的测试数据自动生成方法.首先根据WSDL文档采用随机法自动生成初始测试数据,然后使用合约变异技术进行测试数据的选择,据此可以生成一组达到一定合约变异充分度的有效测试数据,从而提高 Web服务的测试质量和效率.最后实现了一个Web服务的测试数据自动生成工具原型,并通过实验验证了方法的有效性.  相似文献   

12.
为解决软件可靠性测试工程实践上受限于软件的规模、功能和变量的复杂关联而难以开展的问题,提出了一种工程上易于使用的形式语言和测试用例生成方法.由此可清晰描述复杂的功能和变量约束,自动生成指定数量的可靠性测试用例,并通过与实际键值关联,实现可靠性测试用例的自动人机操作输入.对舰艇装备软件典型功能进行了可靠性测试,实验结果表明了该方法的可行性和有效性.  相似文献   

13.
测试数据生成是组合测试的一个关键问题,但是组合测试用例集的构造问题的复杂度是NP完全的。提出了一种成对组合测试用例集整体优化和生成的方法。该方法通过编码机制将测试用例数据的生成问题转换为一个基于二进制编码的最优化问题,同时使用遗传算法对此编码空间进行搜索,并对所发现的最优个体进行解码,构造产生最佳测试用例集。实验结果表明,该方法简单高效,且具有解的质量高、时间消耗小的特点。  相似文献   

14.
将遗传算法应用于覆盖指定路径的测试数据生成已得到了广泛的研究.具体实现中,影响测试数据生成效率的因素很多,如先验知识,GA参数,路径复杂度等.本文在简要介绍应用GA生成测试数据的关键技术后,设计实验分析了影响测试数据生成的部分因素,并据此得出了一些结论.  相似文献   

15.
Code-coverage guided prioritized test generation   总被引:1,自引:0,他引:1  
Most automatic test generation research focuses on generation of test data from pre-selected program paths or input domains or program specifications. This paper presents a methodology for a full solution to code-coverage-based test case generation, which includes code coverage-based path selection, test data generation and actual test case representation in program’s original languages. We implemented this method in an automatic testing framework, eXVantage. Experimental results and industrial trials show that the framework is able to generate tests to achieve program line coverage from 20% to 98% with reduced overall testing effort. Our major contributions include an innovative coverage-based program prioritization algorithm, a novel path selection algorithm that takes into consideration program priority and functional calling relationship, and a constraint solver for test data generation that derives constraints from bytecode and solves complex constraints involving strings and dynamic objects.  相似文献   

16.
基于接口参数的黑箱测试用例自动生成算法   总被引:36,自引:5,他引:31  
测试用例的选择与生成技术是软件测试尤其是黑箱测试的一个重要研究领域,测试用例的质量将直接决定软件测试的科学性和有效性.该文在一般的测试用例选择方法的基础上,提出了一种基于对接口参数进行组合覆盖的黑箱测试用例自动生成算法模型,据此可以生成一个对所有接口参数进行两两组合覆盖的测试用例表.并证明了该方法产生的测试用例具有数量少、能实现对接口参数最大限度组合覆盖的特点,从而可以在提高软件测试质量的同时,降低成本,提高效率.最后介绍了该算法在作者研究开发的测试数据生成工具中的实际效果.  相似文献   

17.
软件测试对确保软件质量有着不可替代的作用。自动化测试框架有效提高了测试效率,自动化测试框架的成熟是软件测试走向标准化的必经之路。文章改进了自动化单元测试框架NUnit,使测试代码和测试数据分离,解决了使用NUnit测试时测试代码存在大量冗余的问题。在改进的NUnit框架中,相似的测试用例只需测试人员编写一次,框架将自动生成其他测试用例。  相似文献   

18.
一种最小测试用例集生成方法   总被引:26,自引:5,他引:26  
聂长海  徐宝文 《计算机学报》2003,26(12):1690-1695
测试用例的数量和质量决定软件测试的成本和有效性.该文提出了一种生成最小测试用例集的方法,该方法首先充分考虑测试目标中各个测试需求之间的相互关系,将满足测试需求的所有可用测试用例进行划分,根据划分的结果生成一个测试用例集,然后利用启发式算法、贪心算法或整数规划方法来消除冗余,对这个测试用例集进行进一步的简化.这种方法与已有方法相比,优点在于它可以生成满足所有测试需求的最小测试用例集.  相似文献   

19.
Testing is often cited as one of the most costly operations in testing dependable systems (Heimdahl et al. 2001). A particular challenging task in testing is test-case generation. To improve the efficiency of test-case generation and reduce its cost, recently automated formal verification techniques such as model checking are extended to automate test-case generation processes. In model-checking-assisted test-case generation, a test criterion is formulated as temporal logical formulae, which are used by a model checker to generate test cases satisfying the test criterion. Traditional test criteria such as branch coverage criterion and newer temporal-logic-inspired criteria such as property coverage criteria (Tan et al. 2004) are used with model-checking-assisted test generation. Two key questions in model-checking-assisted test generation are how efficiently a model checker may generate test suites for these criteria and how effective these test suites are. To answer these questions, we developed a unified framework for evaluating (1) the effectiveness of the test criteria used with model-checking-assisted test-case generation and (2) the efficiency of test-case generation for these criteria. The benefits of this work are three-fold: first, the computational study carried out in this work provides some measurements of the effectiveness and efficiency of various test criteria used with model-checking-assisted test case generation. These performance measurements are important factors to consider when a practitioner selects appropriate test criteria for an application of model-checking-assisted test generation. Second, we propose a unified test generation framework based on generalized Büchi automata. The framework uses the same model checker, in this case, SPIN model checker (Holzmann 1997), to generate test cases for different criteria and compare them on a consistent basis. Last but not least, we describe in great details the methodology and automated test generation environment that we developed on the basis of our unified framework. Such details would be of interest to researchers and practitioners who want to use and extend this unified framework and its accompanying tools.  相似文献   

20.
Existing automated test data generation techniques tend to start from scratch, implicitly assuming that no pre‐existing test data are available. However, this assumption may not always hold, and where it does not, there may be a missed opportunity; perhaps the pre‐existing test cases could be used to assist the automated generation of additional test cases. This paper introduces search‐based test data regeneration, a technique that can generate additional test data from existing test data using a meta‐heuristic search algorithm. The proposed technique is compared to a widely studied test data generation approach in terms of both efficiency and effectiveness. The empirical evaluation shows that test data regeneration can be up to 2 orders of magnitude more efficient than existing test data generation techniques, while achieving comparable effectiveness in terms of structural coverage and mutation score. Copyright © 2010 John Wiley & Sons, Ltd.  相似文献   

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

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