Mapping Artificial Intelligence to Software Testing Concepts

Abstract:

Software testing plays a vital role to gain consumers/end users confidence in the software. In order to ensure quality and reliability before any software is delivered to the client, the developers must know whether the designed software is working as per the end users requirements or not. Testing is important to check whether these requirements are integrated well or not. Today’s world where the market is growing fast and complex, end-to-end automation testing needs to be deployed, But that alone may not be enough. Artificial Intelligence approaches, clubbed with Automation can do wonders and fetch faster results for complex market demands. This paper presents a number of Artificial intelligence approaches, which can be used by in the Software testing environment. Keywords: Software Testing, Test Cases, Test data generation.

Introduction:

Software Testing is the process of evaluating a system or its component(s) with the intent to find whether it satisfies the specified requirements or not. Testing is executing a system in order to identify any gaps, errors, or missing requirements in contrary to the actual requirements.

Application of artificial intelligence techniques in engineering and testing of the software is a progressive area of research that leads to the cross- fertilization of ideas in the middle of the two fields.

Artificial Intelligence techniques, which aim to create software systems that exhibit some form of human intelligence, have been employed to assist or automate the activities in software engineering.

Varieties of AI techniques and tools are used to generate test data, research on data suitability, optimization and analysis of the coverage as well as test management.

In this paper we have tried to focus on some research techniques to aid and automate each phase of software engineering life cycle using artificial intelligence.

Ant Colony Optimization (ACO)

Ants of some species (initially) wanderrandomly, and upon finding food return to their colony while laying downpheromonetrails. If other ants find such a path, they are likely not to keep travelling at random, but instead to follow the trail, returning and reinforcing it if they eventually find food (Ant communication).

ACO is an algorithm that simulates the behaviour of real ants and aid in Test case optimization.In ACO, a set of software agents calledartificial antssearch for good solutions to a given optimization problem. To apply ACO, the optimization problem is transformed into the problem of finding the best path on a weighted graph. The artificial ants (hereafter ants) incrementally build solutions by moving on the graph. The solution construction process is stochastic and is biased by apheromone model, that is, a set of parameters associated with graph components (either nodes or edges) whose values are modified at runtime by the ants.

The first ACO technique was known as Ant System. The approach uses the concept of the capability of ants to locate the shortest route path from their destination to the food source. The method used to communicate information between the individuals is related to paths, and used to decide which path to follow, consists of pheromone trails.

ACO technique has been applied to solve many optimization problems like travelling salesman problem, knapsack problem, distributed networks, telecommunication networks, and test data generation.

Artificial Neural Networks (ANN)

ANN algorithms have been adapted to the problem of software testing effort estimation. Information that flows through thenetworkaffects the structure of the ANN because aneural networkchanges - or learns, in a sense - based on that input and output.It is a system composed of many simple processing elements operating in parallel whose function is determined by network structure, connection strengths, and the processing performed at computing elements or nodes. ANN can exhibit much brain-like behaviours such as learning, association, generalization, feature extraction, optimization and noise immunity. A neural network can perform tasks that a linear program cannot.

When an element of the neural network fails, it can continue without any problem by their parallel nature. A neural network learns and does not need to be reprogrammed. It can be implemented in any application.

Consider three layers in an ANN- as the input layer, which distributes inputs to the hidden layer, and an output layer. The number of nodes used in the input layer and output layer are determined by the problem to which the network is being applied. The number of nodes used in the hidden layer is chosen by the user and there are no clear rules as to how many nodes one should employ in this layer. Consequently, different numbers of hidden nodes were evaluated in this study in an attempt to identify the ‘best’ ANN configuration for software testing effort prediction.

Tabu Search

Tabu search is a metaheuristic algorithm which is used to solve optimization problems. It uses the concept of memory structure that stores the information about the visited solutions and set of rules. Based on the problem, number of parameters are considered by Tabu search such as: objective function (used to calculate the cost of solution), a candidate list (for choosing good neighbour candidates) and memory structure (used to stores the information about the recent moves and the frequently moves of the search). Tabu search is used for automatic generation of structural software testing and is a cost effective approach to optimize the cost of software process that will provide maximum code coverage (in terms of path, conditions and loop coverage)

Data Mining

Data mining is a process of extract of useful information and knowledge from a large database which is further applied for decision making. The parameters included in data mining are clustering, association, path analysis, classification and regression. Data mining algorithms can be efficiently used for automation of tested systems. Mined tools like Pr-Miner, MAPO, PARSEWeb, mined exception-handling rules are used on software data which includes source code, traces of execution process, history of the code revision, bugs reports, documentation etc. Mining models are also used to identifying the equivalence classes in system inputs.

Benefits to Business and Conclusion

Following benefits can be observed by mapping AI to Software Testing:-

Improved quality – Prediction, prevention, and automation using self-learning algorithms

Faster time to market – Significant reduction in efforts with complete E2E test coverage

Cognitively – Scientific approach for defect localization, aiding early feedback with unattended execution

Traceability – Missing test coverage against requirement as well as, identifying dead test cases for changed or redundant requirement

Software testing is the process of validation and verification of the software product. Effective software testing will contribute delivery the reliable and quality oriented software product, more satisfied users. To achieve this many metaheuristic approaches are used in software testing process for test sequence generation, automation of testing, measuring quality, checking reliability, etc.

The usage of AI techniques in Software testing not only reduces the cost but it also guarantees better quality as well as thorough testing.

This emerging technique will definitely transform the present to a next level of futuristic testing environment in the digitalization market. Hence we will be driven towards a more value added and cost effective approach to meet the market demands.

References & Appendix

Author Biography

Sonam Srivastavaworks as an Engineer - Verification & Validation, Siemens Technology and Services Pvt Ltd., Bangalore and has over 7 years of diversified experience in Industrial Automation and Product Testing. Lean Champion for the project currently working in. ISTQB and TUV certified. Trainer for Domain level training in Industrial segment of the organization engaged with..

Abhinav Arya works as a Team Lead- Senior Test Analyst, Cerner Healthcare Solution Pvt. Ltd, Bangalore and have 5 years of diversified experience in Framework UI Tool Development and Software Testing (manual/automation).Currently managing team of 6, handling projects across different solutions. Languages profound in: JavaSE, SQL, UNIX Shell. Also have hands on C.

THANK YOU!