Automated test data generation using an iterative relaxation method

Neelam Gupta, Aditya P. Mathur, Mary Lou Soffa
<span title="">1998</span> <i title="ACM Press"> <a target="_blank" rel="noopener" href="https://fatcat.wiki/container/dj7g645z6zfl5lut4iwy5walyu" style="color: black;">Proceedings of the 6th ACM SIGSOFT international symposium on Foundations of software engineering - SIGSOFT &#39;98/FSE-6</a> </i> &nbsp;
An important problem that arises in path oriented testing is the generation of test data that causes a program to follow a given path. In this paper, we present a novel program execution based approach using an iterative relaxation method to address the above problem. In this method, test data generation is initiated with an arbitrarily chosen input from a given domain. This input is then iteratively refined to obtain an input on which all the branch predicates on the given path evaluate to the
more &raquo; ... desired outcome. In each iteration the program statements relevant to the evaluation of each branch predicate on the path are executed, and a set of linear constraints is derived. The constraints are then solved to obtain the increments for the input. These increments are added to the current input to obtain the input for the next iteration. The relaxation technique used in deriving the constraints provides feedback on the amount by which each input variable should be adjusted for the branches on the path to evaluate to the desired outcome. When the branch conditions on a path are linear functions of input variables, our technique either finds a solution for such paths in one iteration or it guarantees that the path is infeasible. In contrast, existing execution based approaches may require an unacceptably large number of iterations for relatively long paths because they consider only one input variable and one branch predicate at a time and use backtracking. When the branch conditions on a path are nonlinear functions of input variables, though it may take more then one iteration to derive a desired input, the set of constraints to be solved in each iteration is linear and is solved using Gaussian elimination. This makes our technique practical and suitable for automation. Keywords -path testing, dynamic test data generation, predicate slices, input dependency set, predicate residuals, relaxation methods. Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. To copy otherwise, to republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. SIGSOFT '98 11/98 Florida, USA
<span class="external-identifiers"> <a target="_blank" rel="external noopener noreferrer" href="https://doi.org/10.1145/288195.288321">doi:10.1145/288195.288321</a> <a target="_blank" rel="external noopener" href="https://dblp.org/rec/conf/sigsoft/GuptaMS98.html">dblp:conf/sigsoft/GuptaMS98</a> <a target="_blank" rel="external noopener" href="https://fatcat.wiki/release/e47plzz2cfcrlczb4qbfdid6fq">fatcat:e47plzz2cfcrlczb4qbfdid6fq</a> </span>
<a target="_blank" rel="noopener" href="https://web.archive.org/web/20170813171312/https://www.cs.purdue.edu/homes/xyzhang/spring07/Papers/p231-gupta.pdf" title="fulltext PDF download" data-goatcounter-click="serp-fulltext" data-goatcounter-title="serp-fulltext"> <button class="ui simple right pointing dropdown compact black labeled icon button serp-button"> <i class="icon ia-icon"></i> Web Archive [PDF] <div class="menu fulltext-thumbnail"> <img src="https://blobs.fatcat.wiki/thumbnail/pdf/18/b5/18b50d47b89f4b85e56423846b25888fb00608e1.180px.jpg" alt="fulltext thumbnail" loading="lazy"> </div> </button> </a> <a target="_blank" rel="external noopener noreferrer" href="https://doi.org/10.1145/288195.288321"> <button class="ui left aligned compact blue labeled icon button serp-button"> <i class="external alternate icon"></i> acm.org </button> </a>