Application of Genetic Algorithms in Software Testing

Author(s):  
Baowen Xu ◽  
Xiaoyuan Xie ◽  
Liang Shi ◽  
Changhai Nie

Genetic algorithms are a kind of global meta-heuristic search technique that searches intelligently for optimal solutions to a problem. Evolutionary testing is a promise testing technique, which utilises genetic algorithms to generate test data for various testing objectives. It has been researched and applied in many testing areas, including structural testing, temporal performance testing, safety testing, specification-based testing, and so forth. Experimental studies have shown that compared with the traditional techniques, evolutionary testing can greatly improve the testing efficiency.

2014 ◽  
Vol 4 (4) ◽  
pp. 15-35 ◽  
Author(s):  
Ana Filipa Nogueira ◽  
José Carlos Bregieiro Ribeiro ◽  
Francisco Fernández de Vega ◽  
Mário Alberto Zenha-Rela

In Object-Oriented Evolutionary Testing, metaheuristics are employed to select or generate Test Data for Object-Oriented software. The application of search-based strategies to the Software Testing of Object-Oriented Software is fairly recent and is yet to be investigated comprehensively; this article aims to explore, review and contextualize relevant literature and research in this area, while pinpointing open problems and setting grounds for future work.


2020 ◽  
Vol 8 (6) ◽  
pp. 4466-4473

Test data generation is the task of constructing test cases for predicting the acceptability of novel or updated software. Test data could be the original test suite taken from previous run or imitation data generated afresh specifically for this purpose. The simplest way of generating test data is done randomly but such test cases may not be competent enough in detecting all defects and bugs. In contrast, test cases can also be generated automatically and this has a number of advantages over the conventional manual method. Genetic Algorithms, one of the automation techniques, are iterative algorithms and apply basic operations repeatedly in greed for optimal solutions or in this case, test data. By finding out the most error-prone path using such test cases one can reduce the software development cost and improve the testing efficiency. During the evolution process such algorithms pass on the better traits to the next generations and when applied to generations of software test data they produce test cases that are closer to optimal solutions. Most of the automated test data generators developed so far work well only for continuous functions. In this study, we have used Genetic Algorithms to develop a tool and named it TG-GA (Test Data Generation using Genetic Algorithms) that searches for test data in a discontinuous space. The goal of the work is to analyze the effectiveness of Genetic Algorithms in automated test data generation and to compare its performance over random sampling particularly for discontinuous spaces.


2009 ◽  
Vol 18 (01) ◽  
pp. 61-80 ◽  
Author(s):  
ANASTASIS A. SOFOKLEOUS ◽  
ANDREAS S. ANDREOU

Recent research on software testing focuses on integrating techniques, such as computational intelligence, with special purpose software tools so as to minimize human effort, reduce costs and automate the testing process. This work proposes a complete software testing framework that utilizes a series of specially designed genetic algorithms to generate automatically test data with reference to the edge/condition testing coverage criterion. The framework utilizes a program analyzer, which examines the program's source code and builds dynamically program models for automatic testing, and a test data generation system that utilizes genetic algorithms to search the input space and determine a near to optimum set of test cases with respect to the testing coverage criterion. The performance of the framework is evaluated on a pool of programs consisting of both standard and random-generated programs. Finally, the proposed test data generation system is compared against other similar approaches and the results are discussed.


Author(s):  
CHENGYING MAO ◽  
XINXIN YU

The quality of test data has an important impact on the effect of software testing, so test data generation has always been a key task for finding the potential faults in program code. In structural testing, the primary goal is to cover some kinds of structure elements with some specific inputs. Search-based test data generation provides a rational way to handle this difficult problem. In the past, some well-known meta-heuristic search algorithms have been successfully utilized to solve this issue. In this paper, we introduce a variant of genetic algorithm (GA), called quantum-inspired genetic algorithm (QIGA), to generate the test data with stronger coverage ability. In this new algorithm, the traditional binary bit is replaced by a quantum bit (Q-bit) to enlarge the search space so as to avoid falling into local optimal solution. On the other hand, some other strategies such as quantum rotation gate and catastrophe operation are also used to improve algorithm efficiency and quality of test data. In addition, experimental analysis on eight real-world programs is performed to validate the effectiveness of our method. The results show that QIGA-based method can generate test data with higher coverage in much smaller convergence generations than GA-based method. More importantly, our proposed method is more robust for algorithm parameter change.


Author(s):  
Ana Filipa Nogueira ◽  
José Carlos Bregieiro Ribeiro ◽  
Francisco Fernández de Vega ◽  
Mário Alberto Zenha-Rela

In object-oriented evolutionary testing, metaheuristics are employed to select or generate test data for object-oriented software. Techniques that analyse program structures are predominant among the panoply of studies available in current literature. For object-oriented evolutionary testing, the common objective is to reach some coverage criteria, usually in the form of statement or branch coverage. This chapter explores, reviews, and contextualizes relevant literature, tools, and techniques in this area, while identifying open problems and setting ground for future work.


Author(s):  
Sergio Di Martino ◽  
Filomena Ferrucci ◽  
Valerio Maggio ◽  
Federica Sarro

Search-Based Software Testing is a well-established research area, whose goal is to apply meta-heuristic approaches, like Genetic Algorithms, to address optimization problems in the testing domain. Even if many interesting results have been achieved in this field, the heavy computational resources required by these approaches are limiting their practical application in the industrial domain. In this chapter, the authors propose the migration of Search-Based Software Testing techniques to the Cloud aiming to improve their performance and scalability. Moreover, they show how the use of the MapReduce paradigm can support the parallelization of Genetic Algorithms for test data generation and their migration in the Cloud, thus relieving software company from the management and maintenance of the overall IT infrastructure and developers from handling the communication and synchronization of parallel tasks. Some preliminary results are reported, gathered by a proof-of-concept developed on the Google’s Cloud Infrastructure.


2018 ◽  
Vol 12 (7) ◽  
pp. 99
Author(s):  
Faten Hamad

Software testing is a significant stage in software development lifecycle. There are different sorts of' structural software testing methodologies that may be generally utilized and moved forward through enhancing the traverse of all of the conceivable code software paths. The interest for automating data testing is growing; however, manual testing strategies utilization would be expensive and costly. Heuristic measure is being applied to; detect how better the result might be (solution fitness); result development mechanism; and suitableness criteria with stop search mechanism depending on wither a result is found or not. Testing experience could be exploited for finding a solution to the optimization problem by utilizing Meta heuristic procedures. The presented approach might have been tested for five programs to demonstrate the distinctive tests issues. This paper proposes an automatic test data generation approach that use artificial bee colony algorithm for software structural testing, particularly, path testing. This is brought on moving the centralization of data generation testing, as opposed to the automation of the whole testing operation. It executes artificial bee colony algorithm by creating testing data for the criteria of path coverage testing, and then applying the strategy to a group of test programs. 


Author(s):  
Zohreh Karimi Aghdam ◽  
Bahman Arasteh

Software testing is a process for determining the quality of software system. Many small and medium-sized software projects can be manually tested. Nevertheless, due to the widespread extension of software in large-scale projects, testing them will be highly time consuming and costly. Hence, automated software testing (AST) is considered to be as a solution which can ease and simplify heavy and cumbersome tasks involved in software testing. For AST, certain data are needed through which the quality of systems can be evaluated. In this paper, an artificial bee colony (ABC) algorithm was used for solving the issue of test data generation and branch coverage criterion was used as a fitness function for optimizing the proposed solutions. For doing comparisons, seven well-known and traditional programs in the literature were used as benchmarks. The experimental results indicate that our method, on average, outperforms simulated annealing, genetic algorithm, particle swarm optimization and ant colony optimization based on the following four criteria: 99.99% average branch coverage, 99.94% success rate, 3.59 average convergence generation and 0.18[Formula: see text]ms average execution time.


Author(s):  
Nikolai Kosmatov

In this chapter, the authors discuss some innovative applications of artificial intelligence techniques to software engineering, in particular, to automatic test generation. Automatic testing tools translate the program under test, or its model, and the test criterion, or the test objective, into constraints. Constraint solving allows then to find a solution of the constraint solving problem and to obtain test data. The authors focus on two particular applications: model-based testing as an example of black-box testing, and all-paths test generation for C programs as a white-box testing strategy. Each application is illustrated by a running example showing how constraint-based methods allow to automatically generate test data for each strategy. They also give an overview of the main difficulties of constraint-based software testing and outline some directions for future research.


Sign in / Sign up

Export Citation Format

Share Document