Costs Of Agile Testing
-
Upload
schalk-cronje -
Category
Documents
-
view
1.782 -
download
0
description
Transcript of Costs Of Agile Testing
ACCU 2010© Schalk W. Cronjé1 / 45
The Costs of Agile TestingThe Costs of Agile Testing
Schalk W. Cronjé[email protected]
ACCU 2010© Schalk W. Cronjé2 / 45
Agile TodayAgile Today
ACCU 2010© Schalk W. Cronjé3 / 45
Agile TodayAgile Today
● Mature● Well-known methodologies● Embraced by many
– Even if only by lip service● Misunderstood by many● Too easy to tick the boxes
than to deliver value● Tyranny of the urgent
– Discipline
agiletoday
ACCU 2010© Schalk W. Cronjé4 / 45
InstitutionsInstitutions● Sets of internalised rules
supported by values– Has tacit influence– Rules will be contested
● Shape understanding of social meaning + order– Provides a framework for
performance● Shapes of rights + duties
– Political authority– Economic opportunities
Institution
Organisations
People
An organisation can become "institutionalised"Institutions don't last forever
ACCU 2010© Schalk W. Cronjé5 / 45
Scott's Model Scott's Model
Societal Institutions
Organisational Fields
Organisations
Actors(groups/individuals)
diffuse, impose
diffuse, impose
diffuse, impose
invent,negotiate
interpretinnovateerrorinvent,
negotiate
Limitations of cognitive / social rationalitySelective perception
sanctionbehaviour
invent,negotiate
Societal Institutions
ACCU 2010© Schalk W. Cronjé6 / 45
""Excellent system qualities are a Excellent system qualities are a continuous management and engineering continuous management and engineering
challenge, with no perfect solutionschallenge, with no perfect solutions""
Tom Gilb, Overload 85, June 2008
ACCU 2010© Schalk W. Cronjé7 / 45
The Economic ViewThe Economic View
ACCU 2010© Schalk W. Cronjé8 / 45
""You are not here to produce software, You are not here to produce software, you are here to provide you are here to provide valuevalue
to the businessto the business""
Schalk W. Cronjé
ACCU 2010© Schalk W. Cronjé9 / 45
Why take an economic view?Why take an economic view?
● It helps to quantify the effects of multiple interacting variables
● It helps us to understand that the customer is not the only judge of value
● By using an economic framework it can allow us to maximise value, including
– cycle time– product cost– development expense
● It helps to communicate with non-technical decision makers
ACCU 2010© Schalk W. Cronjé10 / 45
Cost of QualityCost of Quality
● Appraisal costs– Discovering condition of hardware & 3rd-party
software components● Internal failure costs
– Defects found before shipment● External failure costs
– Defects found after shipment● Prevention costs
– Costs for preventing all of the above
ACCU 2010© Schalk W. Cronjé11 / 45
deliveredbuild
Batch DevelopmentBatch Development
Feature 3 DevFeature 2 Dev
Feature 4 Dev
Feature 1 Dev Feature 1 QAFeature 2 QAFeature 3 QAFeature 4 QA
ACCU 2010© Schalk W. Cronjé12 / 45
deliveredbuild
Batch DevelopmentBatch Development
Feature 3 DevFeature 2 Dev
Feature 4 Dev
Feature 1 Dev
BugDB
Feature 1 QAFeature 2 QAFeature 3 QAFeature 4 QA
defect trickle feed
Total Time = devt1 .. devt
4 + qat
1 …qat
4 + fixdelay + fixtime + retest time
Feature 5+ Dev
Feature 5+ QA
deliveredbuild
Retest fixes QA
ACCU 2010© Schalk W. Cronjé13 / 45
deliveredbuild
Time FactorsTime Factors
Feature 3 DevFeature 2 Dev
Feature 4 Dev
Feature 1 Dev
BugDB
Feature 1 QAFeature 2 QAFeature 3 QAFeature 4 QA
defect trickle feed
Feature 5+ Dev
Feature 5+ QA
deliveredbuild
Retest fixes QA
understandingspecs
time from raising defect until it is available for testing
Building testinfrastructure
time tore-test
basic buildverification
ACCU 2010© Schalk W. Cronjé14 / 45
FeedbackFeedback
● Faster feedback makes learning faster and more efficient
● Co-location improves communication● Faster feedback provides a sense of control● Large batches leads to slower feedback
ACCU 2010© Schalk W. Cronjé15 / 45
Optimising Batch SizeOptimising Batch Size
● U-curve optimisation● Holding cost includes delay
in time to learn● Transaction cost includes
overhead in releasing a build for testing
Transaction cost
Batch size
Total Cost
Holding cost
Cost
_________________________________________________ 2 x Cost per Batch x Total features in project-------------------------------------------------- Holding cost per feature√
Optimal Batch Size
ACCU 2010© Schalk W. Cronjé16 / 45
""If you only quantify one thing, If you only quantify one thing, quantify the cost of delayquantify the cost of delay""
Don Reinertsen
ACCU 2010© Schalk W. Cronjé17 / 45
""Time counts more than moneyTime counts more than money""
Don Reinertsen
The Attention PrincipleThe Attention Principle
ACCU 2010© Schalk W. Cronjé18 / 45
Building an Agile Testing Building an Agile Testing ModelModel
ACCU 2010© Schalk W. Cronjé19 / 45
Simple Flow ModelSimple Flow Model
Specify Develop QA
Ready QA QAComplete
ReleasedSpec Dev DevComplete
SpecComplete
Kanban Board
Isn't this waterfall?
ACCU 2010© Schalk W. Cronjé20 / 45
Reducing Learning TimeReducing Learning Time
● Writing test specifications after the development is costly in time
– Knowledge decay– Leads to incomplete designs
● Move the test specification up-front before any development starts
– This is part of requirements discovery– It broadens the perspective of the programmer– Allows us to distinguish between automated checks
and human testing
ACCU 2010© Schalk W. Cronjé21 / 45
Reducing Learning TimeReducing Learning Time
Specify Develop QA
+Time to specify
+Time to develop
-Time to re-work
-Time to re-test
Test specification
ACCU 2010© Schalk W. Cronjé22 / 45
Quantifying Learning TimeQuantifying Learning Time
● Can you convert time saved to a monetary value? Before After
Avg cycle days to spec 2 4
Avg cycle days to develop 8 10
Avg cycle days to test 13 8
Avg rework days during test
5 1
Total 23 22
Cost $8,118.00 $7,872.00
(*) Data in graph is from an insignificant data set and provides no conclusive proof. It is for illustrative purposes only
ACCU 2010© Schalk W. Cronjé23 / 45
Change the Flow ModelChange the Flow Model
Specify Develop & Check Verify
● Ensure the all automated checks are included in the development stage
● Free up a Verification stage for exploratory testing and validating that process has been fulfilled.
ACCU 2010© Schalk W. Cronjé24 / 45
Change the Flow ModelChange the Flow Model
Specify Develop & Check Verify
+Time to develop
+More testing people
-Time to re-work
-Time to re-test
ACCU 2010© Schalk W. Cronjé25 / 45
The Role of the TesterThe Role of the Tester
● Up-front involvement to build in quality● Help to build test infrastructure up-front during
the development phase● Work with developer to critically review what
is being automated.
ACCU 2010© Schalk W. Cronjé26 / 45
Apply Lean PrinciplesApply Lean Principles
Specify Develop & Check Verify
● Make the system pull-based● Reduce the batch size● Limit the work-in-progress● One feature end-to-end● If the flow breaks, fix it immediately
ACCU 2010© Schalk W. Cronjé27 / 45
Apply Lean PrinciplesApply Lean Principles
Specify Develop & Check Verify
+Time to develop
+Time to test
-Average Cycle time
-Inherited delay cost
-Waiting time
ACCU 2010© Schalk W. Cronjé28 / 45
Team CompositionTeam Composition
ACCU 2010© Schalk W. Cronjé29 / 45
The Classic Dev-QA TeamThe Classic Dev-QA Team
● This is the easiest team to adapt● Requires the will to change to a new working
practices● If teams are distributed then groups of
programmers and testers must be co-located.
ACCU 2010© Schalk W. Cronjé30 / 45
The "No Testers" TeamThe "No Testers" Team
● All development + testing done by same people.
● Requires T-skilled people● Initial slow down of cycle time due to learning
of new skills OR reduction in quality delivered
ACCU 2010© Schalk W. Cronjé31 / 45
Paired TeamsPaired Teams
● Pair up people with different skills to work on same feature
– Feature teams are not a new concept● Could be perceived to have higher person
cost per feature– Instead of distributing the person cost over multiple
queues, the cost is combined into a single queue– Can actually lead to reduced cycle time.
ACCU 2010© Schalk W. Cronjé32 / 45
Real-world measurementsReal-world measurements
ACCU 2010© Schalk W. Cronjé33 / 45
Real-world measurementsReal-world measurements
M1 M2 NF1 NF2
READY 4 6 5 1h
SPEC 1 0.5 6 0.5
SPEC/Completed 2 0.5 1 0.5
DEV + Check 2 1 13 4
DEV + Check / Completed
3 6 4 18
VERIFY 3 7 8 1
VERIFY/Completed 2 5 6 18
Blockages 0.5 1h 2 1h
Total 17 26 43 42
Specify Develop & Check Verify
Average cycle days per feature
ACCU 2010© Schalk W. Cronjé34 / 45
What is wrong?What is wrong?
M1 M2 NF1 NF2
READY 4 6 5 1h
SPEC 1 0.5 6 0.5
SPEC/Completed 2 0.5 1 0.5
DEV + Check 2 1 13 4
DEV + Check / Completed
3 6 4 18
VERIFY 3 7 8 1
VERIFY/Completed 2 5 6 18
Blockages 0.5 1h 2 1h
Total 17 26 43 42
Average cycle days per feature
ACCU 2010© Schalk W. Cronjé35 / 45
What is wrong?What is wrong?
M1 M2 NF1 NF2
READY 4 6 5 1h
SPEC 1 0.5 6 0.5
SPEC/Completed 2 0.5 1 0.5
DEV + Check 2 1 13 4
DEV + Check / Completed
3 6 4 18
VERIFY 3 7 8 1
VERIFY/Completed 2 5 6 18
Blockages 0.5 1h 2 1h
Total 17 26 43 42
Average cycle days per feature
Excessive long time between feature availability and testing. Is there enough testing bandwidth? Or is this team just cheating?
ACCU 2010© Schalk W. Cronjé36 / 45
What is wrong?What is wrong?
M1 M2 NF1 NF2
READY 4 6 5 1h
SPEC 1 0.5 6 0.5
SPEC/Completed 2 0.5 1 0.5
DEV + Check 2 1 13 4
DEV + Check / Completed
3 6 4 18
VERIFY 3 7 8 1
VERIFY/Completed 2 5 6 18
Blockages 0.5 1h 2 1h
Total 17 26 43 42
Average cycle days per feature
ACCU 2010© Schalk W. Cronjé37 / 45
What is wrong?What is wrong?
M1 M2 NF1 NF2
READY 4 6 5 1h
SPEC 1 0.5 6 0.5
SPEC/Completed 2 0.5 1 0.5
DEV + Check 2 1 13 4
DEV + Check / Completed
3 6 4 18
VERIFY 3 7 8 1
VERIFY/Completed 2 5 6 18
Blockages 0.5 1h 2 1h
Total 17 26 43 42
Average cycle days per feature
Is this 2 days due to re-work? Is there a problem in the development phase?
ACCU 2010© Schalk W. Cronjé38 / 45
How do these teams compare?How do these teams compare?
M1 M2 NF1 NF2
READY 4 6 5 1h
SPEC 1 0.5 6 0.5
SPEC/Completed 2 0.5 1 0.5
DEV + Check 2 1 13 4
DEV + Check / Completed
3 6 4 18
VERIFY 3 7 8 1
VERIFY/Completed 2 5 6 18
Blockages 0.5 1h 2 1h
Total 17 26 43 42
Average cycle days per feature
ACCU 2010© Schalk W. Cronjé39 / 45
ExerciseExercise
● Analyse the previous listed teams and comment on their process (with liberty)
● Is it possible to identify points where cost of delay can be calculated?
● How would you identify the holding costs and transaction costs?
● Can you improve testing/quality control and what is the expected and hidden costs?
ACCU 2010© Schalk W. Cronjé40 / 45
The End GameThe End Game
ACCU 2010© Schalk W. Cronjé41 / 45
The institution hits backThe institution hits back
Societal Institutions
Organisational Fields
Organisations
Actors(groups/individuals)
imposing existing failed processes
diffuse, impose
slow diffusionor no diffusion
attempting to introduce change
speaking at public conferences, publishing articlessuccess
propagates from known champions
Limitations of cognitive / social rationalitySelective perception
sanctionbehaviour
invent,negotiate
Societal Institutions
ACCU 2010© Schalk W. Cronjé42 / 45
Making Testing more AgileMaking Testing more Agile
● Reduce learning time - bring test specification forward
● Pair up developers and testers● Be intelligent about what is being automated.
ACCU 2010© Schalk W. Cronjé43 / 45
Investing in Agile TestingInvesting in Agile Testing
● Building infrastructure● Good testers demand equivalent
remuneration to good programmers● Put measurements in place● Cross-train people to create T-skilled sets● Smooth the Flow● Recognise that transition will take months,
even a year
ACCU 2010© Schalk W. Cronjé44 / 45
Cost of Agile TestingCost of Agile Testing
● Appraisal costs● Internal failure costs● External failure costs● Prevention costs
– Checks against external deliverables– Automating checks (TDD)– Building the capacity for addressing critical
issues without too much interruption to other development.
– Training & Practising the mind-set
ACCU 2010© Schalk W. Cronjé45 / 45
SummarySummary
● Balanced teams reduce costs● Shared problem-solving can reduce feature
cycle time● Reduced cycle time will have a direct
influence on delay cost.● Following a process does not make you
testing agile● Measure to improve● You will operate within an institutional context