首页 | 本学科首页   官方微博 | 高级检索  
相似文献
 共查询到20条相似文献,搜索用时 0 毫秒
1.
2.
浦云明 《计算机应用》2008,28(4):1023-1025
分析了结构性测试和功能性测试方法及其优劣,提出了一种平衡结构性测试和功能性测试的模型方法,即定义-使用测试方法。该方法定义了介于全路径指标和全边之间的测试覆盖指标,提供了一种检查缺陷可能发生点的系统化方法。模拟实例结果表明,定义-使用测试方法能够显著提高发现缺陷的效率。  相似文献   

3.
The aim of software testing is to find faults in a program under test, so generating test data that can expose the faults of a program is very important. To date, current stud- ies on generating test data for path coverage do not perform well in detecting low probability faults on the covered path. The automatic generation of test data for both path coverage and fault detection using genetic algorithms is the focus of this study. To this end, the problem is first formulated as a bi-objective optimization problem with one constraint whose objectives are the number of faults detected in the traversed path and the risk level of these faults, and whose constraint is that the traversed path must be the target path. An evolution- ary algorithm is employed to solve the formulated model, and several types of fault detection methods are given. Finally, the proposed method is applied to several real-world programs, and compared with a random method and evolutionary opti- mization method in the following three aspects: the number of generations and the time consumption needed to generate desired test data, and the success rate of detecting faults. The experimental results confirm that the proposed method can effectively generate test data that not only traverse the target path but also detect faults lying in it.  相似文献   

4.
The general procedure for data acquisition in digital signal processing systems is to acquire a block of data and then analyse it. In a single-processor system, a considerable amount of data can be lost because, while data is being analysed by the processor, it is not sampled from the A/D converter. A dual-tasking machine has therefore been developed for continuous data analysis. The design requirements of the system are discussed. A block diagram of the system is presented, and the analogue-to-digital converter board is described in detail. The memory interchange board is also considered in depth.  相似文献   

5.
The aim of software testing is to find faults in a program under test, so generating test data that can expose the faults of a program is very important. To date, current studies on generating test data for path coverage do not perform well in detecting low probability faults on the covered path. The automatic generation of test data for both path coverage and fault detection using genetic algorithms is the focus of this study. To this end, the problem is first formulated as a bi-objective optimization problem with one constraint whose objectives are the number of faults detected in the traversed path and the risk level of these faults, and whose constraint is that the traversed path must be the target path. An evolutionary algorithmis employed to solve the formulatedmodel, and several types of fault detectionmethods are given. Finally, the proposed method is applied to several real-world programs, and compared with a random method and evolutionary optimization method in the following three aspects: the number of generations and the time consumption needed to generate desired test data, and the success rate of detecting faults. The experimental results confirm that the proposed method can effectively generate test data that not only traverse the target path but also detect faults lying in it.  相似文献   

6.
Path-oriented Random Testing (PRT) aims at generating a uniformly spread out sequence of random test data that execute a single control flow path within a program. The main challenge of PRT lies in its ability to build efficiently such a test suite in order to minimize the number of rejects (test data that execute another control flow path). We address this problem with an original divide-and-conquer approach based on constraint reasoning over finite domains, a well-recognized Constraint Programming technique. Our approach first derives path conditions by using backward symbolic execution and computes a tight over-approximation of their associated subdomain by using constraint propagation and constraint refutation. Second, a uniform random test data generator is extracted from this approximated subdomain. We implemented this approach and got experimental results that show the practical benefits of PRT based on constraint reasoning. On average, we got a two-order magnitude CPU time improvement over standard Random Testing on a set of paths extracted from classical benchmark programs.  相似文献   

7.
McCabe提出的基本路径测试法(McCABE T J. A complexity measure. IEEE Transactions on Software Engineering, 1976, SE-2(4): 308-320)是动态白盒测试技术中严谨而有效的方法,但存在测试用例设计效率较低的问题,影响了该方法在工程项目中的广泛应用。为了解决这一问题,从被测程序的基本结构出发,提出一种基于组合的基本路径测试用例设计方法。创建一种基于Z路径覆盖的基本单元图,构建由基本单元图组合形成控制流图的组合规则,以此为基础提出了基本路径组合算法,该算法只需一次扫描程序得到程序基本结构的路径集,将这些路径进行组合即可生成被测程序的基本路径集。该方法比McCabe所提出的方法构造过程简洁,能有效提高基本路径测试用例设计的效率。  相似文献   

8.
分析了轨道衡普遍采用的多传感器输出并联产生误差的原因.介绍了应用基于算术平均值与分批估计的数据融合方法处理轨道衡多传感器输出的数据,提高轨道衡准确度。  相似文献   

9.
The point-to-point quickest path problem is a classical network optimization problem with numerous applications, including that of computing driving directions. In this paper, we define a lower bound on the time-to-target which is both accurate and fast to compute. We show the potential of this bound by embedding it into an A algorithm. Computational results on three large European metropolitan road networks, taken from the OpenStreetMap database, show that the new lower bound allows us to achieve an average reduction of 14.36%. This speed-up is valuable for a typical web application setting, where a server needs to answer a multitude of quickest path queries at the same time. Even greater computing time reductions (up to 28.06%) are obtained when computing paths in areas with moderate speeds, e.g. historical city centers.  相似文献   

10.
传统基路径覆盖测试用例生成方法通过程序图求出圈复杂度,然后再得出程序的一组基路径,最后分别针对基路径组中的每条路径求出相应的测试用例,不仅繁琐,而且忽视了代码的语义相关性,导致存在路径不可达问题,也就无法生成对应的测试用例.提出了一种新的方法,利用遗传算法动态运行程序,逐渐逼近被测程序的真实逻辑圈复杂度,直接生成满足基路径覆盖测试用例的最小集合,不存在路径不可达问题.实验结果表明,该算法能够有效地生成满足基路径覆盖的测试用例.  相似文献   

11.
In general, LCSAJ testing more thoroughly exercises the control structure of a piece of software than does either statement or branch testing. Despite this, the exceptionally small number of papers which detail experience of using LCSAJ testing clearly indicates that its popularity falls considerably short of that of the other two methods. One factor that has contributed to this situation is the apparent absence of any attempt to assess the effort entailed by LCSAJ testing in practice, thereby precluding any meaningful cost-effectiveness analysis of the method. Such an attempt is reported in this paper.A significant influence on the effort associated with LCSAJ testing is the number of test paths that must be generated to achieve a specified level of cover, and this is determined by the number of such paths that are found to be infeasible. Effort, therefore, is dependent upon the effectiveness of the path generation method/strategy in avoiding infeasible paths. The attempt to assess the effort entailed by LCSAJ testing which is reported here makes use of a new path selection strategy. This strategy seeks to reduce,a priori, the incidence of infeasible paths in the test set that is generated. Details of the strategy are presented, as are the results which were obtained by applying it to a set of subroutines. From the results, a measure of the effort entailed in employing the strategy is deduced. Subsequently, it is argued that features of the strategy enable pertinent comments to be made not only about the effort associated with employing the strategy, but also about the effort entailed by LCSAJ testing in general.  相似文献   

12.
We show an Ω(m) lower bound on the number of queries required to test whether a Boolean function depends on at most m out of its n variables. This improves a previously known lower bound for testing this property. Our proof is simple and uses only elementary techniques.  相似文献   

13.
ContextEvolutionary algorithms have proved to be successful for generating test data for path coverage testing. However in this approach, the set of target paths to be covered may include some that are infeasible. It is impossible to find test data to cover those paths. Rather than searching indefinitely, or until a fixed limit of generations is reached, it would be desirable to stop searching as soon it seems likely that feasible paths have been covered and all remaining un-covered target paths are infeasible.ObjectiveThe objective is to develop criteria to halt the evolutionary test data generation process as soon as it seems not worth continuing, without compromising testing confidence level.MethodDrawing on software reliability growth models as an analogy, this paper proposes and evaluates a method for determining when it is no longer worthwhile to continue searching for test data to cover un-covered target paths. We outline the method, its key parameters, and how it can be used as the basis for different decision rules for early termination of a search. Twenty-one test programs from the SBSE path testing literature are used to evaluate the method.ResultsCompared to searching for a standard number of generations, an average of 30–75% of total computation was avoided in test programs with infeasible paths, and no feasible paths were missed due to early termination. The extra computation in programs with no infeasible paths was negligible.ConclusionsThe method is effective and efficient. It avoids the need to specify a limit on the number of generations for searching. It can help to overcome problems caused by infeasible paths in search-based test data generation for path testing.  相似文献   

14.
基于控制流程图的路径覆盖测试的改进方法研究   总被引:1,自引:0,他引:1       下载免费PDF全文
软件测试是当前软件生成重要的研究课题。文中从源程序开始,引入基本块的方法将源程序转换为相应的控制流程图。并采用图形的方法将路径构造相应的自动机,通过对自动机中回边的处理,生成简化的并与之等价的自动机。经过若干变换后,可在自动机上直观地求出路径覆盖的条数和相应的信息。此方法实现路径覆盖的目标,简化路径覆盖生成过程,步骤直观,且减少路径生成数。  相似文献   

15.
基于事件权重的GUI测试路径生成方法   总被引:1,自引:0,他引:1  
江琴  刘琳岚  苏曦  蔡轲 《计算机应用》2009,29(5):1382-1384
针对GUI事件驱动特性产生无限多个测试路径的问题,提出在事件流图中考虑事件权重的GUI测试路径生成方法。分析了事件流图模型,采用层次分析法计算事件的权重,通过遍历事件流图生成GUI测试路径。该方法减少了测试路径的数目,生成的测试路径更具有效性,提高了测试效率。  相似文献   

16.
Automated test data generation plays an important part in reducing the cost and increasing the reliability of software testing. However, a challenging problem in path-oriented test data generation is the existence of infeasible program paths, where considerable effort may be wasted in trying to generate input data to traverse the paths. In this paper, we propose a heuristics-based approach to infeasible path detection for dynamic test data generation. Our approach is based on the observation that many infeasible program paths exhibit some common properties. Through realizing these properties in execution traces collected during the test data generation process, infeasible paths can be detected early with high accuracy. Our experiments show that the proposed approach efficiently detects most of the infeasible paths with an average precision of 96.02% and a recall of 100% of all the cases.  相似文献   

17.
18.
Introduced in 1976 by Hennell, Woodward, and Hedley, the Linear Code Sequence and Jump (LCSAJ) has since been named the jump‐to‐jump path (JJ‐path). If all JJ‐paths in a piece of code have been tested, then it is guaranteed, for example, that all of the code's branches and all of its statements will likewise have been tested. JJ‐path testing is thus said to include both branch and statement testing. Over the years, much work has been carried out on the inclusion relation, and this is also true of a closely‐linked relation that is known as subsumption. Not surprisingly, some of the work in the literature has focussed on the criteria of executing all JJ‐paths and sequences of such, and how these criteria relate to other path coverage and test data criteria. Unfortunately, certain results involving JJ‐paths in the context of inclusion, as portrayed in a widely referenced and influential paper, are in error. Consequently, the main purpose of this paper is to rectify this situation. Copyright © 2008 John Wiley & Sons, Ltd.  相似文献   

19.
In this paper, we establish a new model for path planning with interval data which arises in a variety of applications. It is formulated as minimum risk-sum path problem  : given a source-destination pair in a network G=(V,E)G=(V,E), traveling on each link e in G   may take time xexe in a prespecified interval [le,ue][le,ue] and take risk (ue-xe)/(ue-le)(ue-xe)/(ue-le), the goal is to find a path in G from the source to the destination, together with an allocation of travel times along each link on the path, so that the total travel time of links on the path is no more than a given time bound and the risk-sum over the links on the path is minimized. Our study shows that this new model has two features that make it different from the existing models. First, the minimum risk-sum path problem is polynomial-time solvable, and second, it provides many solutions that vary with time bounds and risk sums and leaves the choice for decision makers. Therefore, the new model is more flexible and easier to use for the path planning with interval data.  相似文献   

20.
分析了基于稳定路径的数据传输方式,发现如果采用传统的可靠数据传输协议存在效率低下的问题,提出了一种基于稳定路径的可靠数据传输协议(RDTSP).采用CPN(coloured Petri net) tools对协议进行了建模分析.状态空间结果表明,该协议是可靠、可行和完备的.  相似文献   

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

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