Andrew Knight - 7 Major Software Testing Trends

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 45

7 Major Software Testing Trends

Pandy Knight
Automation Panda
Applitools Developer Advocate
Test Automation University Director

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


suki_thefrenchie_

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com
7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com
7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com
7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com
7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com
Tools and technologies may change,
but fundamentals remain the same.

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


Trend #1:
End-to-end web testing
is a three-way battle.

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


Selenium
Popular among testers

C#, Java, JavaScript, Ruby, Python

All major browsers

WebDriver protocol

Low-level browser interactions only

Middle-speed execution

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


Selenium Cypress
Popular among testers Popular among developers

C#, Java, JavaScript, Ruby, Python JavaScript only

All major browsers Chrome, Edge, Firefox, Electron

WebDriver protocol In-browser JavaScript

Low-level browser interactions only Full framework with advanced features

Middle-speed execution Slowest execution

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


Selenium Cypress Playwright
Popular among testers Popular among developers The dark horse

C#, Java, JavaScript, Ruby, Python JavaScript only C#, Java, JavaScript, Python

All major browsers Chrome, Edge, Firefox, Electron Chromium+, Firefox, WebKit

WebDriver protocol In-browser JavaScript Debug protocols

Low-level browser interactions only Full framework with advanced features Full framework with advanced features

Middle-speed execution Slowest execution Fastest execution

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


Selenium Cypress Playwright
Open source Open source Open source

Open standards (WebDriver) In-browser JavaScript Debug protocols

Open governance Run by Cypress.io Run by Microsoft

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com
Other web testing tools
● Webdriver IO remains very popular
● Protractor is deprecated and will reach end-of-life in 2023
● Puppeteer’s spiritual successor is Playwright
● Selenium IDE is being redeveloped as an Electron app
● Other tools exist but have small footprints

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


Trend #2:
Component testing
is the new integration testing.

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


17
7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com
7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com
When testing anything for the web, we believe that
tests should view and interact with the application in
the same way that an actual user does.

Anything less, and it's hard to have confidence that


your application is doing what it is supposed to.

Source: https://www.cypress.io/blog/2022/06/01/cypress-10-release/

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


We want the best of both worlds:

The simplicity and sensibility of manual testing.

The speed and scalability of automated testing.

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


Trend #3:
Visual testing
has become indispensable.

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com
7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com
7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com
7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com
Modern Cross-Platform Testing

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


Trend #4:
Performance testing
is easier and more vital than ever.

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


Chrome DevTools Performance Tab

TAU Course:
28

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


Google Lighthouse

29

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


Playwright Performance Testing
John Hill’s Talk:
https://bit.ly/3xKQqqT
const client = await page.context().newCDPSession(page);
await client.send('Performance.enable');

await page.goto('https://www.google.com/');
await page.click('[aria-label="Search"]');
await page.fill('[aria-label="Search"]', 'playwright');

await Promise.all([
page.waitForNavigation(), John Hill’s Code:
https://bit.ly/3zCuaSq
page.press('[aria-label="Search"]', 'Enter')
]);

let perfMetrics = await client.send('Performance.getMetrics');


console.log( perfMetrics.metrics );

Source: https://github.com/unlikelyzero/js-perf-toolkit

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


Trend #5:
Testing needs to be
faster than ever.

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


The Rule of 1’s

For 1 test

UI Test ≈ 1 minute

API Test ≈ 1 second

Unit Test ≈ 1 millisecond

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


The Rule of 1’s

For 1000 tests

1K UI Tests ≈ 17 hours

1K API Tests ≈ 17 minutes

1K Unit Tests ≈ 1 minute

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


Ways to speed up test execution
1. Focus on most valuable behaviors instead of complete coverage
2. Push tests down the Pyramid
3. Optimize automated operations:
a. Run tests in parallel
b. Prep data using APIs
c. Cache login credentials
d. Use smart waiting instead of hard sleeps
e. Limit each test to covering one individual behavior

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


Ways to speed up test development
1. Use a mature framework with good Developer Experience (DX)
2. Apply visual testing techniques for assertions
3. Require test automation as part of the Definition of Done
4. Bridge the gap between tester and developer

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


Continuous Integration, Testing, & Delivery

White Box Tests


Commit Build Black Box Tests Delivery
Static Analysis

Run this pipeline for every commit (or small batch of commits)
Target max execution time ≈ 15 minutes

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


Trend #6:
Machine learning algorithms
need separate approaches.

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


Amazon’s
Recommendation
System

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


TAU Course for Testing Machine
Learning Models
https://testautomationu.applitools.com/testing-machine-learning-models/

39

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


Trend #7:
Autonomous testing is coming.

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


The First Wave: Manual Conversion
● Historically, testing was done manually
○ Teams built huge repositories of step-by-step test procedures

● Automation enabled tests to run faster and more frequently


○ Start by automating existing manual tests
○ Focus on improving test execution
○ It was common to run tests after a nightly or weekly build

● Manual conversion had learning pains


○ Long tests became fragile scripts
○ Many teams tried to achieve 100% automation

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


The Second Wave: CI/CD/CT
● Continuous Integration enabled tests to run continuously
○ The focus became triggering tests
○ Fast feedback caught problems sooner
○ Full embrace of Agile and DevOps

● Teams changed their approach to automation


○ Unit and integration tests became just as important as end-to-end tests
○ Black-box tests covered individual behaviors rather than grand tours
○ Speed and reliability became more important than coverage

● The barrier to entry was high


○ Developing automation required full software development skills
○ Some teams rose to the challenge while others failed

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


The Third Wave: Autonomous Testing
● Testing = Interaction + Verification
○ In the first two waves, humans had to define both parts of the equation

● Autonomous Testing is when automation figures out what and how to test
○ AI agents learn behaviors in the product under test
○ Then, they automatically figure out the interactions to trigger the behaviors

● Autonomous Testing will be a gamechanger


○ We aren’t “there yet,” but it’s coming in the next few years
○ We already are partially there (with tech like visual assertions)
○ Success will require learning from testers and coaching testers

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com


7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com
7 Major Software Testing Trends
1. End-to-end web testing is a three-way battle
2. Component testing is the new integration testing
3. Visual testing has become indispensable
4. Performance testing is easier and more vital than ever
5. Testing needs to be faster than ever
6. Machine learning algorithms need separate approaches
7. Autonomous testing is coming

Twitter Blog Puppy TAU

7 Major Trends in Software Testing | Andrew Knight | @AutomationPanda | AutomationPanda.com

You might also like