Font Size: a A A

Research On Improved Adaptive Random Testing Based On Data Similarity Classification

Posted on:2022-10-23Degree:MasterType:Thesis
Country:ChinaCandidate:W F SunFull Text:PDF
GTID:2518306506463274Subject:Computer Science and Technology
Abstract/Summary:PDF Full Text Request
With the increasing demand for modern software systems,software failures in software systems arise.Software testing,as one of the important methods to ensure the quality of software,plays an extremely critical role in the whole software life cycle.Among the many functional testing methods,the most basic testing method is Random Testing(RT).Specifically,it randomly selects test cases from the whole test suite until a certain condition is met,such as finding a failure in the software system.However,since random testing makes little use of additional information,its testing effectiveness is limited.Therefore,Adaptive Random Testing(ART)is proposed to ensure the randomness of test cases while enabling them to be evenly dispersed throughout the input domain.In this thesis,we conduct an extensive study on test case generation techniques from the perspective of test case similarity.Meanwhile,a set of generation techniques are proposed to quickly achieve uniform distribution of test cases based on data similarity.Finally,a system of test case generation is designed and implemented for the proposed method.The main contributions of the thesis as follows:1.It is found that the main factors affecting the performance of the adaptive random testing algorithm include: boundary effect(the generated test cases tend to be more boundary-oriented)and large time overhead required for test case generation.To this end,an adaptive random testing method based on nearest neighbor divide and conquer is proposed.Specifically,the input domain is spatially partitioned to reduce the time overhead for candidate test cases to find their nearest neighbors for executed test cases by using the location of sub-regions.It is also considered that,in the adaptive random testing approach,the number of test cases near the boundary region is much more than the number of test cases near the center region.The algorithm generates test cases only in the blank subregion,thus improving the quality of test case distribution.The results show that the proposed algorithm further improves the effectiveness of the traditional adaptive random testing in the high dimensions.Meanwhile,it reduces the time complexity of the adaptive random testing to a linear level.2.In response to the poor performance of the algorithms that have been proposed to reduce the time overhead of adaptive random testing in high dimensions,a new method,based on cluster algorithm,is further proposed.Based on the spatial similarity of test cases,a traditional clustering algorithm is used to cluster the test cases with high similarity into the same cluster.When determining the nearest executed test cases for a candidate test case,only the executed test cases located in the same cluster as the candidate test cases are subjected to distance calculation,thus reducing the time overhead.The algorithm uses the maximum number of test cases in a cluster as the threshold,so the time overhead of test case generation is acceptable in any dimension.3.With the increasing complexity of software products,the cost of manual software testing becomes increasingly expensive.The software testing process tends to be automated.Therefore,this thesis designs and implements a prototype system of adaptive random testing based on data similarity.The system executes the whole testing process in an automated manner,which contains test configuration of the program under test,variation testing and analysis,test case generation,data analysis and visualization.Finally,the effectiveness and feasibility of the system are verified through a series of experiments.
Keywords/Search Tags:Software testing, Adaptive random testing, Nearest neighbor search, Cluster analysis
PDF Full Text Request
Related items