One of the most recent buzzwords in the software development industry is artificial intelligence (AI). But what does it really mean? How does AI in the context of software test automation differ from its broader definition?
What do we mean when we talk about AI and its sister term, machine learning? I thought I would clear up our usage so it’s clear how we are using AI and machine learning to advance the state-of-the-art in software testing.
How to Implement AI in Test Automation (It’s Not Just Buzz)
Artificial intelligence is one of the most overloaded buzzwords in the marketplace. “AI” conjures up images of things like all-powerful super-computers, hell-bent on human destruction; voice-control assistance in the way of Alexa or Siri; computer chess opponents; or self-driving cars.
Wikipedia defines AI research as “…the study of ‘intelligent agents:’ any device that perceives its environment and takes actions that maximize its chance of successfully achieving its goals.” But that’s a little too abstract. I like to think of AI as the ability of a computer program or machine to think (reason for itself) and learn (collect data and modify future behavior in a beneficial way). It’s in this definition that we start to see something more meaningful in the context of what AI means for software development tools and technology.
It’s also important to realize that the scope of what is considered “AI” changes over time. At one time, for example, optical character recognition (OCR) was considered state-of-the-art in AI. Or the question-and-answer responses from Siri and Alexa, which at one time were considered state-of-the-art, are now largely taken for granted and not always considered AI. The same thing will happen with software testing tools — innovations in automation today will become expected as new capabilities evolve. But for now, let’s consider AI in software test automation in 2019.
AI in Software Test Automation in 2019
The use of AI in software development is still in its infancy, and the level of autonomy is much lower than seen in more evolved areas such as self-driving systems or voice-assisted control, although it is still driving forward in the direction of autonomous testing. The application of AI in software testing tools is focused on making the software development lifecycle easier. Through the application of reasoning, problem-solving, and, in some cases, machine learning, AI can be used to help automate and reduce the amount of mundane and tedious tasks in development and testing.
“Don’t test automation tools do this already?” you might ask.
And the answer is of course, “Yes! They do!” But they have limitations.
Where AI shines in software development is when it is applied to remove those limitations, to enable software test automation tools to provide even more value to developers and testers. The value of AI comes from reducing the direct involvement of the developer or tester in the most mundane tasks. (Human intelligence is still very much needed in applying business logic, etc.)
For example, consider that most (if not all) test automation tools run tests for you and deliver results. Most don’t know which tests to run, so they run all of them or some predetermined set. So what if an AI-enabled bot can review the current state of test status, recent code changes, code coverage, and other metrics, decide which tests to run, and then run them? Bringing in decision-making that’s based on changing data is an example of applying AI (And Parasoft does this, by the way). The software is effectively able to replace the developer/tester in the decision-making process. The benefit of applying this to a CI/CD pipeline is clear.
AI and Machine Learning
So, what about machine learning? Machine learning can augment the AI by applying algorithms that allow the tool to improve automatically by collecting the copious amounts of data produced by testing.
Machine learning research is a subset of overall AI research, with a focus on decision-making based on previously observed data. This is an important aspect of AI overall, as intelligence requires modifying decision-making as learning improves. In software testing tools, though, machine learning isn’t always necessary — sometimes an AI-enabled tool is best manually fine-tuned to suit the organization using the tool, and then the same logic and reasoning can be applied every time, regardless of the outcome.
In other cases, data collection is key to the decision-making process, and machine learning can be extremely valuable, requiring some data initially and then improving or adapting as more data is collected. For example, code coverage, static analysis results, test results, or other software metrics, over time, can inform the AI about the state of the software project.
Deep Learning
Machine Learning has its own subset called Deep Learning, which is built on the processing of a vast amount of data to learn from. Such data, in most cases, is represented by multilayered Neural Networks — they are models inspired by the net of human neurons, helping computers to acquire new knowledge and to reason highly intelligently.
The key aspect of Deep Learning is a huge amount of information represented by Neural Networks to drive the decision-making process. Such amount of data is not always available or not applicable in software testing – maybe that’s why we don’t see many cases of Deep Learning usage in those areas yet. One possible example would be “learning” from tens of millions of lines of code to understand different types of security violations, and to implement a static analysis engine based on such deep learning model.
The Future of AI and Machine Learning in Software Testing
This is an important area of research and development at Parasoft. Excitingly, our current offerings are just the beginning, and our ongoing research in AI and ML continues to bring new ways to integrate these technologies into our products.
We are in active R&D in this space, continuing to pursue further applications of artificial intelligence and machine learning to augment our software testing tool suite. There are many routes of research, but the end goal is clear: to help teams develop and test their code more efficiently and effectively, to create higher quality software at speed.
For additional information on the ways AI, machine learning and deep learning are being applied to software testing, click HERE to register for the Webinar, “AI-Driven Test Automation: Modernizing the Delivery of Critical Government Applications.”