Smart Testing in the Age of Machine Learning

This blog was previously published by the author in his personal blog site.

Artificial Intelligence and Machine Learning are becoming wide spread across various industries. It plays a vital role in developing sci-fi sounding stuff such as Self driving cars and more practical things that touch human lives almost every day, like Voice assistants, Chatbots, Smart power grids etc.

In Software testing, transition from traditional approach to CI/CD driven DevTestOps model is essential to cope up with increased release cadence. Test automation has helped keeping up with the required delivery speed, however adapting AI/ML capabilities in test automation will be a go-forward approach.

Evolution of Software testing

To begin with, let’s review how Software testing has evolved over past few years.

As testing evolved, so does the tools & techniques. However to keep up with the pace of change in the technology, testing strategies must reinvent and bring in required change.

Current challenges in Software Testing

From days of slow paced deliveries of waterfall model to the present day era of continuous application delivery; each phase has its own challenges.

  • Size of applications & functional workflows makes achieving the complete test coverage always a challenge.
  • Frequent releases and reduced time for testing.
  • Rapid changes in applications resulting in huge maintenance of automated tests, as workflows keep changing.
  • Pressure of controlling defect leakage in production

While some of the available tools can be leveraged in addressing these challenges to a certain extent, there is a profound need of an Intelligent Test Automation.

With the sheer amount of data generated by applications, test cases, devices etc,; can we use AI/ML algorithms to make informed decisions? After all AI is all about data!

AI/ML/DL – A brief overview

Artificial Intelligence (AI), Machine Learning (ML) & Deep Learning (DL) are interconnected fields, where latter two helps the former in solving complex problems using a data driven approach.

  • Artificial Intelligence (AI) is a method of getting machines to think like humans and help make informed decisions based on the available data.
  • Machine Learning (ML) is a subset of AI, which uses set of algorithms to keep feeding data to machines. There are three types of machine learning capabilities:
    • Supervised learning (Labelled data)
    • Unsupervised learning (Unlabelled data)
    • Reinforced learning (Adaptation based on environment)

Software testing will mostly be using “Supervised Learning”, as the data will be of certain type.

  • The third subset of AI is Deep Learning, which makes use of neural networks to help machines solve complex problems.

The following diagram depicts workflow for training a machine to make informed decisions using AI/ML and DL techniques.

Smart testing using AI/ML 

In “Current challenges in software testing” section, we noted three most commonly seen problems by Software Quality professionals. Let’s explore a possibility to build smart, intelligent tools/frameworks that use data (ML) and help bring intelligence (AI) in Software testing to solve these problems.

Problem Statement #1: Ensuring test coverage, in fast paced product delivery cycle: Modern applications  are required to support multiple platforms such as Deployment configurations, Mobile devices, Web browsers, Operating systems, Multi cloud environments etc., essentially making their compatibility matrix quite large. This directly impacts the number of workflows the applications need to support in order to cater to variety of different use cases. With reduced development and release cycles, it becomes essential that QE teams must ensure testing is complete within stipulated time with the required coverage achieved. Automation is largely adapted by many organisations, which help reduce manual efforts and in-turn the delivery times. However ensuring the coverage still remains a challenge.

How Smart testing tools can help?

Build process, Unit tests, Code coverage all generate variety of artefacts. This information can be used to ensure we are testing enough, in following ways:

    • Group of expert manual testers, will do exploratory testing of the application. Logs (data) generated by this activity can then be fed to ML algorithms to build model for automated tests. This will be an additional step towards ensuring we are covering corner cases in product testing with a touch of human creativity.

Problem Statement#2: Rapidly Changing applications need heavy automation maintenance: Test automation requires maintenance as applications undergo changes over the period of time. In case of agile development, these changes are more frequent during the initial days of product development. To keep up with the development cycle, automation is must to have, however the total time available for testing also gets pulled into the time required to maintain your automated tests.

How Smart testing tools can help?

  • AI based, ‘Auto correcting’ automated tests; can keep track of changes happening in the product and make adjustments to test automation code.

Problem Statement#3: Controlling defect leakage in production: Bugs found in production, which ideally should be caught during testing, put QE teams on spot. Therefore serious attempts are always made to ensure enough testing is done. However considering the differences in test V/s production environments, application workloads etc. not every single workflow can be tested.

How Smart testing tools can help?

  • Many applications upload logs as part of their call-home capability. While these logs hide the sensitive information, they likely to give good insight to understand application usage patterns. By doing analysis of these logs, Smart testing frameworks can figure out application usage patterns and use this information to fine tune functional/non-functional test suites.
  • Smart regression suites can be created by analysing code changes while fixing bugs or enhancing functionality. The insight gained can be used to focus more on weak areas in the product.

Choosing the right tools

Although the concept of using AI/ML in software testing is relatively new, there are handful of commercial tools available in this space. Most are catering to UI Testing needs.

Frameworks, libraries available in opensource can be used to build machine learning models. The selection will vary based on the technology stack, availability of programming skills etc. However the general guideline is to choose a Programming language which is flexible and has built-in support for extensive libraries and frameworks.

Choosing the right tools is just one part in enabling AI/ML in software testing, equally critical is learning required skills. Application of AI in any domain requires following skills and software testing is not an exception.

  • Programming – Python & R are most commonly used.
  • Data science – Big data concepts, Data modelling etc.
  • Mathematics & Statistics

Conclusion 

Though AI/ML is around for a decade. However wide spread use of Internet connected smart devices, Wearable tech etc. is making it a commodity now. Two most important driving factors behind acceptance of AI/ML is; “Data” & “Tools” that can leverage it to make meaningful insights. In current times, both are available in abundance. Software testing rely heavily on Data to make important decisions such as product release – go/no-go and with the right strategy, can leverage AI/ML based tools to make these decisions with greater confidence.

 
Share:

Related Posts

Generative AI and the changing face of Software Development Lifecycle

Generative AI and the changing face of Software Development Lifecycle

Generative AI is revolutionizing many IT segments, and one of such segments is software product development lifecycle (SDLC). This blog summarizes how Generative AI is transforming SDLC with its applications, benefits, and examples.

Share:
Revolutionizing the Impact of Gen AI in Data Centers and Network Infrastructure

Revolutionizing the Impact of Gen AI in Data Centers and Network Infrastructure

The advent of Generation AI (Gen AI) is changing the model of data centers and network infrastructure, indicating a new era of efficiency, scalability, and intelligence. Gen AI, representing the integration of AI into systems, is revamping how data is processed, analyzed, and managed within these critical environments. Network infrastructure benefits from self-optimizing capabilities, guaranteeing optimal performance and security. Read the blog to explore the impact of Gen AI in the datacenter infrastructure management.

Share:
Telecom Technology Trends 2024: Navigating the Evolution

Telecom Technology Trends 2024: Navigating the Evolution

The telecom industry is witnessing a rapid network transformation, enabled by a wide range of pioneering technology trends. The industry is gearing up for constant innovation in the coming year 2024. The digital disruption with technologies like 5G, IoT, and AI set the pace for modern market trends and business development in 2024. Read the blog to explore the major technology trends driving competitive and innovative business strategies in the telecom industry.

Share:
Retail Transformation

Revolutionizing Retail: The Top 7 GenAI Use Cases Transforming the Industry

The revolutionary applications of Generative Artificial Intelligence (GenAI) are enhancing the retail landscape. GenAI can ensure supreme end-user experience through pioneering applications such as personalized recommendations, virtual shopping assistants, supply chain optimization, and dynamic pricing strategies. This enhances targeted marketing strategies, enabling businesses to raise efficiency and innovation in a progressively competitive market. Read the blog to understand the transformative use cases that redefine how businesses drive the retail industry in the future.

Share:
Technology Trends 2024

Technology Trends 2024- The CXO perspective

In the rapidly evolving landscape of 2024, technology trends are reshaping industries and redefining business strategies. From the C-suite perspective, executives are navigating a dynamic environment where artificial intelligence, augmented reality, and blockchain are not just buzzwords but integral components of transformative business models. The Chief Experience Officers (CXOs) are at the forefront, leveraging cutting-edge technologies to enhance customer experiences, streamline operations, and drive innovation. This blog delves into the strategic insights and perspectives of CXOs as they navigate the ever-changing tech terrain, exploring how these leaders are shaping the future of their organizations in the era of 2024’s technological evolution.

Share:
Generative AI Shaping Future Industries

[Infoblog] Generative AI Shaping Future Industries

Generative AI is at the forefront of innovation, harnessing the power of machine learning algorithms to create new and original content, from images and music to entire virtual environments. This infographic depicts how Gen AI is evolving industries and shaping its future.

Share: