Font Size: a A A

Research On Test Case Optimization Method Based On Spectrum-based Fault Localization

Posted on:2020-02-08Degree:MasterType:Thesis
Country:ChinaCandidate:K ZhangFull Text:PDF
GTID:2428330590452378Subject:Software engineering
Abstract/Summary:PDF Full Text Request
With the increasing scale and complexity of software,there will inevitably be some errors in software.Correcting software errors through debugging technology has become a common means for developers to deal with software errors.Error location is an important step in debugging technology.However,traditional error location is usually done by hand,which is not only time-consuming and laborious,but also difficult to ensure the quality of error location.Automatic error location technology can improve the efficiency of error location and ensure the quality of error location.Therefore,automatic error location technology has become an important research content in the field of software engineering.The method of error location based on program spectrum is a representative one.The existing error location methods based on program spectrum do not fully mine the coverage information of failed test cases,which leads to the unsatisfactory positioning accuracy.In the process of error location,because of the large number of test cases to be executed,the program spectrum information to be collected is more,which increases the cost of error location.How to improve the accuracy of error location and reduce the cost of error location has become an urgent problem to be solved.In order to solve the above problems,this paper proposes two methods of error location based on heuristic rules and test case reduction based on vector similarity.The main work of this paper is as follows:(1)A variety of heuristic rules are proposed,and experiments verify the influence of the proposed rules on spectrum-based error location methods.On the basis of traditional spectrum-based error location,the maximum coverage failure test cases,the minimum coverage failure test cases,the maximum distance failure test cases and the minimum distance failure test cases are selected respectively.Based on the selected test case coverage information,the number of statements to be checked in the suspicion list is further reduced to improve the accuracy of error location.(2)A test case reduction method based on vector similarity is proposed,and the effectiveness of the proposed method in test case reduction is verified by experiments.Through SMC similarity,Jaccard similarity,Dice similarity and Hamming similarity,the similarity between failed test cases and successful test cases is calculated respectively.Successful test cases are sorted based on these four similarity measures,and test cases are selected in turn until the overall coverage is satisfied,test casereduction is stopped to reduce the scale of test case set.(3)A Java-based error location prototype system is designed and implemented.The prototype system can automatically collect test case coverage information and run results,and calculate statement suspicion.On this basis,the error location method based on heuristic rules and the test case reduction method based on vector similarity are implemented.
Keywords/Search Tags:debugging techniques, fault Localization, heuristic rules, vector similarity, test case reduction
PDF Full Text Request
Related items