Font Size: a A A

An Adaptive Random Testing Approach Based On Coverage And Its Application In Object Oriented Software Testing

Posted on:2018-08-27Degree:MasterType:Thesis
Country:ChinaCandidate:H H GeFull Text:PDF
GTID:2348330533459278Subject:Software engineering
Abstract/Summary:PDF Full Text Request
With the continuous improvement of the informationization degree,the Object Oriented Programming(OOP)technology has been used in most of softwares,which are called the Object Oriented Software(OOS).People have always focused their eyes on its quality.However,software testing is confronted with unprecedented challenges because of the three inherent characteristics of OOS.Among many testing methods,the one based on Random Testing(RT)is the most widely used.However,because it is unsatisfied with the efficiency and the effect of the RT method,some scholars have improved this method in recent years.As a result,an Adaptive Random Testing(ART)method is proposed and some good testing results have been achieved.According to the phenomenon that the failure areas in software are usually continuous,Professor Chen T Y proposed an improved RT method,which is the ART method.When the ART method is executed,the executed test case set and the candidate test case set are typically generated.The test case which is the farthest from all the excuted test cases is selected as the next executable case from the candidate test case set.If it does not cause the program to fail,it will be added to the executed test case set.In order to increase the effectiveness of the selected test cases,we decide to introduce the coverage information.The statement coverage and the distance information should be taken into consideration to improve the fault detection effectiveness.To solve the above problems,the method of dynamic test case generation for object oriented software based on coverage and the ART method based on coverage are proposed.The feasibility of these two methods is proved by the conduction of experiments and statistic analysis.Furthermore,a testing prototype system is designed and implemented.The main work of this paper is described as follows.1.A method of dynamic test case generation for objected oriented software based on coverage is proposed.In this method,the dynamic monitoring technology for coverage sort(DMTCS)is illustrated,and three modules of the technology are analyzed in detail,which are preprocessing module,program inserting pile module and sorting module.In program inserting pile module,three types of pile insertion rules are defined to be used to monitor four types of coverage information of the test cases during the execution.Among the four types of coverage information,the statement coverage information is selected to apply to the technology of dynamic test case generation for object oriented software,which leads to that the generated test cases contain the information of larger statement coverage,which improves the testing effectiveness.2.An adaptive random testing method based on coverage is proposed.In this method,the paper illustrates that the candidate test case set is generated by using the method of the dynamic test case generation for objected oriented software based on coverage.Then,the formula for the sum of the weight is defined as Weight=Distance+Coverage,in which the sum of the distances between each test case of the candidate test case set and all the excuted test cases should be calculated and normalized firstly,then the value of the Weight is calculated according to the statement coverage information of each test case in the candidate test case set.The test case which has the maximum value of the Weight is chosen as the next executabletest case.At last,the test method of OOS is described,including the testing flow,the implementation of relevant algorithms and the automated analysis of testing results.3.A testing prototype system named ARTCovPS is designed and implemented.It includes the class diagram input module,the parameter configuration module,the DTCG-COV execution module,the test driver module,the FSCS-COV algorithm execution module and the result statistic module.The ARTCovPS system can conduct the whole testing process with better feasibility.
Keywords/Search Tags:Object oriented software, Adaptive random testing, Coverage, Distance information, Test case generation
PDF Full Text Request
Related items