Font Size: a A A

Research On Automatic Generation Of Test Cases Based On Symbolic Execution

Posted on:2019-03-03Degree:MasterType:Thesis
Country:ChinaCandidate:R G RenFull Text:PDF
GTID:2428330566467897Subject:Software engineering
Abstract/Summary:PDF Full Text Request
Software testing is an important part of the entire software life cycle.Each company is investing more and more in software testing.The automatic generation of test cases is very important for the enterprise and the entire software testing.Although the test case generation tool on the market has achieved a certain role,there are also problems such as low path coverage,excessive redundant test cases,and low execution efficiency.Therefore,this paper studies the symbolic execution execution test cases as the subject.Through the research,it is found that the symbolic execution technology generation test cases are mostly valid use cases and have a thigh coverage rate,but there are also path missing coverage and path growth leads to a rapid path.Inflated,inefficient implementation of the problem.Aiming at these problems,this paper proposes a stochastic depth traversal strategy based on abstract.This strategy combines random and deep traversal methods to traverse the symbol execution tree,save the executed path in the digest function,and avoid repeated traversal.For the path expansion,a method for performing secondary coverage after similar pruning prediction is proposed.This method obtains call graphs between program functions after code instrumentation,analyzes and calculates which codes are not covered,and generates the symbol execution tree after traversing.The path is calculated based on similarity prediction.Some uncovered paths and paths with similar similarities are pruned.Finally,test case generation and execution are performed.This article also designed automated instrumentation methods to collect path constraints,bootstrap programs into symbolic execution,and assign variables to symbols.Experiments show that this traversal strategy can improve code coverage and execution efficiency compared to the previous improvement method.After comparing the similarity path prediction pruning re-execution test case with other methods,the test result analysis shows that the execution time is shortened.As the number decreases,the code coverage increases while the risk of path expansion decreases.
Keywords/Search Tags:instrumentation, symbol tree traversal, symbolic execution, similar path, use case generation
PDF Full Text Request
Related items