KEMBAR78
Holistic testing in DevOps | PDF
@janetgregoryca
Holistic Testing in DevOps
NovaTech – January 2022
Janet Gregory
Twitter: @janetgregoryca
Agile Testing Fellowship DragonFire Inc.
With material from Lisa Crispin
Copyright 2022
@janetgregoryca
Focusing on….
- What do I mean by holistic testing in DevOps
- Testing early
- Testing and your deployment pipeline
- Testing your releases
- Applying testing activities to observing and learning
2
@janetgregoryca
Typical DevOps loop
3
@janetgregoryca
What we hear about DevOps is …
•Continuous delivery
•Continuous deployment
•Testing in production
•The build pipeline
•Tools and more tools
4
@janetgregoryca
• Small batches to delivery
• Builds quality into your product
• Improves time to market
• Supports continuous testing and delivery
• Provides for continuous learning and improvement
by observing production use
holistic
@janetgregoryca
6
We test here!
Dan Ashby -https://danashby.co.uk/2016/10/19/continuous-testing-in-devops/
@janetgregoryca
My version of the DevOps cycle
@janetgregoryca
Holistic testing
@janetgregoryca
@janetgregoryca
Testing early …..
•Is about collaboration
•Helps the customers get what
they want
•Helps prevent defects in code
@janetgregoryca
How are we
going to test
this?
and working
through
examples
What are the
accessibility
standards?
What is the
biggest risk?
Let’s
prioritize
quality?
Testing early is
asking questions
@janetgregoryca
Questions to ask about testing
•What kinds of testing is carried out?
•Who is responsible for creating and executing the
different types of tests?
•How does the team decide what to automate and at
what levels?
@janetgregoryca
To encourage whole team testing,
@janetgregoryca
During
development
• Guide development with
examples (BDD/ATDD)
14
• Teams decide what to automate
• Exploratory testing for unknowns
@janetgregoryca
Let’s move to the right
side of the loop
•Deployment pipeline
•Testing in production
•Observing and
monitoring
•Learning
@janetgregoryca
Compile
and run
unit tests
locally
Deploy to
test env.
Check-in
and run
unit tests
Run API
test suite
Deploy to
dev env.
Run smoke
tests
Requires
human
intervention
Automated
steps Exploratory
testing
Accessibility
testing
……
UI test suite ……..
Testing is the of DevOps
@janetgregoryca
Where can you start?
Draw the pipeline – on a white board or a remote tool
Look for bottlenecks
• Ex. Wait times for someone to review test results
Look for merging issues and long standing branches
• Testing becomes more complicated
• Automation often breaks
Aim for fast feedback!
@janetgregoryca
Questions to ask
about the pipeline
• What tests run on what environment?
• Which are human-centric tests? Which are
automated?
• Who is responsible for following up on failures?
• How fast is the response to failures?
@janetgregoryca
Local
Unit tests
Static analysis
Test doubles
Run unit
tests
Run api auto
tests
Observability
Monitoring
Test in Prod
Run API
auto tests
Security,
load,
performance,
recovery….
Run
workflow
auto tests
UAT
Your deployment pipeline & tests
@janetgregoryca
The release
Image from: https://dzone.com/articles/blue-green-deployment-for-cloud-native-application
@janetgregoryca
Observing
Early in the cycle,
• help to define what you want to measure
• create queries and alerts for monitoring (helps testing)
• think about good metrics to use with feature flags for A/B testing
• Then we observe, and monitor
@janetgregoryca
Learn
What did our
observations tell us?
@janetgregoryca
23
Experiment
Set a goal, craft a hypothesis, and find ways to measure
progress. For example:
● Goal: reduce cycle time
● Hypothesis: “We believe that automating more tests
at the API level will shorten our cycle time by 10%
over the next month.”
If you don’t see progress, try another model or goal
@janetgregoryca
Optimize the whole - reduce cycle time, improve quality
- from concept to in the customer's’ hands
Work identified Work started
Work
completed
Process / Cycle Time
@janetgregoryca
Cultural aspects
• Silos / turfs
• Looking at individual optimization
• It’s not my job (to test, to code, to ….)
• Separate DevOps team
• Do teams feel safe to experiment?
• How is information funneled up /
down?
@janetgregoryca
Simple / obvious
Complex Complicated
Chaotic
Cynefin Model – Dave Snowden
@janetgregoryca
No one right way
to build TRUST
----
different contexts
different guardrails
@janetgregoryca
What makes a holistic testing strategy work?
● Commitment to a level of quality
○ Understand what’s valuable to customers
○ Focus on bug prevention vs. bug detection
● Fast feedback loops
● Diverse perspectives, skill sets, biases
@janetgregoryca
References
• https://agiletester.ca
• https://janetgregory.ca/blog
• Donkeys & Dragons YouTube channel https://tinyurl.com/agiletfellow
• https://lisacrispin.com
• A Practical Guide to Testing in DevOps (Katrina Clokie)
• https://medium.com/@copyconstruct/testing-in-production-the-safe-
way-18ca102d0ef1
• Continuous Delivery: Reliable Software Releases Through Build, Test,
and Deployment Automation (Jez Humble and David Farley)
• Hendrickson, Elisabeth, Explore It!
@janetgregoryca
Agile Testing: A Practical Guide for Testers and Agile Teams
More Agile Testing: Learning Journeys for the Whole Team
Agile Testing Condensed: A Brief Introduction
By Janet Gregory and Lisa Crispin
Agile Testing Fellowship
https://agiletestingfellow.com
Contact info
https://janetgregory.ca
Email: janet@agiletester.ca
Twitter: janetgregoryca

Holistic testing in DevOps