The document summarizes a presentation on patterns of automation for simplifying test code. It discusses reasons to automate testing like allowing exploration of different browsers, devices and security aspects. It presents patterns like specification by example, acceptance test driven development, and using page objects. It emphasizes keeping test code clean and not automating more than needed.
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
Patterns of Automation: Simplify Your Test Code
1. T3
Test Automation
5/8/2014 9:45:00 AM
Patterns of Automation: Simplify
Your Test Code
Presented by:
Jeff Morgan
LeanDog
Brought to you by:
340 Corporate Way, Suite 300, Orange Park, FL 32073
888-268-8770 ∙ 904-278-0524 ∙ sqeinfo@sqe.com ∙ www.sqe.com
2. Jeff Morgan
LeanDog
Chief technology officer and a cofounder of LeanDog, Jeff “Cheezy” Morgan has been teaching
classes and coaching teams on agile and lean techniques since early 2004. Most of his work
has focused on the engineering practices used by developers and testers. For the past few
years Cheezy has experienced great success and recognition for his work focused on helping
teams adopt Acceptance Test Driven Development using Cucumber. He has authored several
popular Ruby gems used by software testers and the book Cucumber & Cheese-A Testers
Workshop.
25. Pattern
A pattern, apart from the term's use to mean
"Template"[a], is a discernible regularity in the world or
in a manmade design. As such, the elements of a
pattern repeat in a predictable manner.!
- Wikipedia
42. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Ready Development Test Review Done
Product
Owner
Developer Tester
43. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Ready Development Test Review Done
Product
Owner
Developer Tester
44. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Ready Development Test Review Done
Product
Owner
Developer Tester
45. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Ready Development Test Review Done
Product
Owner
Developer Tester
46. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Ready Development Test Review Done
Product
Owner
Developer Tester
47. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Ready Development Review Done
Product
Owner
Developer Tester
48. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Ready Development Review Done
Product
Owner
Developer Tester
49. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Ready Development Review Done
Product
Owner
Developer Tester
50. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Ready Development Review Done
Product
Owner
Developer Tester
51. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Ready Development Review Done
Product
Owner
Developer Tester
52. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Ready Development Review Done
Product
Owner
Developer Tester
?
53. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Ready Development Review Done
Product
Owner
Developer Tester
54. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Ready Development Review Done
Product
Owner
Developer Tester
55. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Ready Development Review Done
Product
Owner
Developer Tester
56. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Ready Development Review Done
Product
Owner
Developer Tester
Done
57. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Ready Development Review Done
Product
Owner
Developer Tester
Done
58. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Ready Development Review Done
Product
Owner
Developer Tester
Done Done
64. Test Drive Code With Pair
Automate Acceptance Tests
Code
Test
Developer
Tester
65. Test Drive Code With Pair
Automate Acceptance Tests
Code
Test
Developer
Tester
66. Make Acceptance Tests Pass
Test Drive Code With Pair
Automate Acceptance Tests
Code
Test
Developer
Tester
67. Make Acceptance Tests Pass
Test Drive Code With Pair
Automate Acceptance Tests
Code
Test
Developer
Tester
68. Make Acceptance Tests Pass
Test Drive Code With Pair
Automate Acceptance Tests
Code
Test
Developer
Tester
Exploratory Testing
69. Make Acceptance Tests Pass
Test Drive Code With Pair
Automate Acceptance Tests
Code
Test
Developer
Tester
Exploratory Testing
70. Make Acceptance Tests Pass
Talk
Test Drive Code With Pair
Automate Acceptance Tests
Code
Test
Developer
Tester
Exploratory Testing
71. Make Acceptance Tests Pass
Talk
Test Drive Code With Pair
Automate Acceptance Tests
Code
Test
Developer
Tester
Exploratory Testing
72. Make Acceptance Tests Pass
Talk
Prevent Defects
Test Drive Code With Pair
Automate Acceptance Tests
Code
Test
Developer
Tester
Exploratory Testing
73. Make Acceptance Tests Pass
Talk Prevent Defects
Test Drive Code With Pair
Automate Acceptance Tests
Code
Test
Developer
Tester
Exploratory Testing
74. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Creation Elaboration Validation WIP
Product
Owner
75. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Creation Elaboration Validation WIP
Product
Owner
Tester
76. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Creation Elaboration Validation WIP
Product
Owner
Tester
Developer
77. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Creation Elaboration Validation WIP
Product
Owner
Tester
Developer
78. Copyright 2013 LeanDog, Inc. All Rights Reserved. Do not copy or distribute without permission.
Creation Elaboration Validation WIP
Product
Owner
Tester
Developer
Progressive
Elaboration
92. Test begins
Insert data
needed for
this test
Test
executes
Test removes
data
Best
Repeat for
next test
Another option
Insert all
data
necessary
for all tests
Execute all
tests
Remove all
data
93. Test begins
Insert data
needed for
this test
Test
executes
Test removes
data
Best
Repeat for
next test
Another option
Insert all
data
necessary
for all tests
Execute all
tests
Remove all
data
Yet another option
Recondition
data from
last test
execution
Execute all
tests
94. Do not repeat data
Do not repeat data
Do not repeat data
Do not repeat data
Do not repeat data
Do not repeat data
Do not repeat data